Posts by Benjamim Coelho • 46 points
6 posts
- 
		2 votes3 answers66 viewsA: Can someone explain to me what this program does?the % operator returns the rest of the division of its arguments, if the rest of the Count division by 17 and 19 is zero, then it is divisible by the two. I believe this is the functionality of the… javaanswered Benjamim Coelho 46
- 
		0 votes2 answers55 viewsA: Resume part of a string in function ReturnHello! You can change the function type to: char* RetornaString(char *pString1, char *pString2) So you can return a part of any string, for example: char* RetornaString(char *pString1, char… canswered Benjamim Coelho 46
- 
		0 votes1 answer76 viewsA: Help with recursive function in PythonHello, the recursive version of the factorial function looks good to me, just a hint: the case of x==1 and x==0 is the same (Return 1) so you don’t need to separate these cases into two different… 
- 
		0 votes1 answer35 viewsA: Scanner not workingFirst of all, I don’t know which MVC model you are using, but in my projects the View module never extends the controller, each of the modules must be completely independent! In your View class, in… 
- 
		1 votes1 answer198 viewsA: How can I read a txt file in C, line by line?Hello. You are on the right track when using fgets. If you read the documentation of this function you will see that it returns null when it reaches the EOF or no characters are read. And what you… 
- 
		0 votes3 answers138 viewsA: The main function and its arguments. How does it manage to assign to its argc and *argv[] arguments the parameters passed via terminal?Basically, the compiler parses by the empty space character " ". Thus counts the number of arguments (not forgetting that main in "./main" is the first argument of the program). So if you need to…