Most voted "printf" questions
53 questions
Sort by count of
-
-1
votes1
answer71
viewsWhere to use the n in the printf?
Hi, my question is where to put the \n. I see several situations where the \n is used at the end of printf: int x = 2, y = 3; printf("X = %d\n",x); printf("Y = %d",y); But also, I see it being used…
-
-1
votes1
answer28
viewsprintf printing strange numbers
#include <stdio.h> #include <locale.h> void main() { int i, n; setlocale(LC_ALL, "Portuguese"); printf("Digite um número: "); scanf("%d", &n); printf("\nSequência decrescente de %d…
-
-2
votes1
answer61
viewsC language code print pairs from one to fifty
Programming exercise in C: Statement: "Write a program that prints all pairs between 2 and 50. To know if the number is even, just see if the rest of the division by 2 is equal to 0." what I did:…