Posts by Gabriel A. S. Braga • 347 points
13 posts
-
1
votes1
answer206
viewsA: Error with C Strings
This problem you are having there is due to the fact of buffer keyboard not being clean, when you press enter gets a /n stored in the keyboard buffer, to end this error just clear the buffer. For…
canswered Gabriel A. S. Braga 347 -
2
votes2
answers57
viewsA: Problem in a function parameter
Hello, I think it was not very clear what you wanted with the problem, next time try to give better examples of what you want and what is happening, besides explaining better what the program does…
-
0
votes2
answers447
viewsA: Limit, or capacity of a Vector
Just put a printf() warning that it has reached the limit after the for that this in its function int lerVectorDeInteiros(int vetor[MAX]), for always when he comes to the end of that for, or better…
-
2
votes2
answers767
viewsA: Help with code implementation and functions
Look, I’m warning you that this answer will be huge, because the show is big, So let’s get started. The libraries used are the following: #include <stdio.h> /* adiciona as funções de input e…
-
7
votes1
answer2293
viewsA: How do I stop organizing tables in while?
Just replace the ' n’s of the first and second printf with ' t’s, in this way it will not break the line, which in case is ' n', and will still give a tab, in case t, (equivalent to four spaces).…
-
1
votes2
answers841
viewsA: Problem with recursiveness and pointers
First before going for the answer I would like to say that your program had several "little mistakes", so first of all I would like to point them out just so you know where you went wrong. #include…
-
1
votes1
answer1001
viewsA: How to convert a String Char by storing it in an Integer array in C?
Basically what you should do is a technique known as casting, casting server for you to tell the computer that certain kind of data should be interpreted as the data you are casting, putting in…
canswered Gabriel A. S. Braga 347 -
1
votes3
answers1680
viewsA: How to put a whole word inside a char?
Dude basically you can’t do that with a char "normal", a variable of this type is made to store only one character, so you can store a string (string) in a variable it is necessary that you use a…
canswered Gabriel A. S. Braga 347 -
1
votes3
answers1075
viewsA: I want to pass a parameter that is in the main for a function and perform a calculation, pointer exercise and function, how do I do?
Well basically from what I understand you want to know how to pass a variable per parameter in C, it is important to know that in C there are two ways to pass variables per parameter in a function,…
canswered Gabriel A. S. Braga 347 -
0
votes1
answer341
viewsA: Problems organizing a C-struct
Dude basically your mistake is in for, your for is as follows, for( i=0; i<j; i++ ), this way when you make your vector in the index i + 1, when your for, reach the last loop it will buffer…
canswered Gabriel A. S. Braga 347 -
0
votes2
answers68
viewsA: Vector by Parameter in C
In this case it is not necessary to put the & before the vector, let’s analyze why, its function is the following void FPVazia(TipoPilha *Pilha) note that what you ask for as a parameter is a…
-
1
votes1
answer127
viewsA: Accentuation in C
Basically all letters, numbers and special characters have a representation in the ascii table, this table shows which binary would represent that character you are wanting the computer to print or…
-
0
votes1
answer79
viewsA: Problem passing array as parameter
Guy, I kind of misunderstood what you want with this function, so if you can explain to me I’m sure I can improve my answer to your better understanding, but going straight to the answer. First pass…
canswered Gabriel A. S. Braga 347