- ..clause 1..: Basic knowledge
- ..clause 2..: Program readout
- Memo
- ..clause 4..: Description type
- ..clause 5..: Basic knowledge(example solution)
- ..clause 6..: Program readout(example solution)
- Memo(example solution)
- ..clause 8..: Description type(example solution)
[ 1-1 ]
What is called the character string enclosed with ""
[ 1-2 ]
Which sign is used by mathematics in C language instead of the sign of ×?
[ 1-3 ]
Which sign is used by mathematics in C language instead of the sign of ÷?
Example solution
[ 1-4 ]
Is the method that is called very much though the real number is expressed in C language used?
Example solution
[ 2-1 ]
How are you displayed when the following program is executed?
#include <stdio.h> int main(void) { printf("%d\n",20 / 7); printf("%f\n",20.0 / 7.0); return 0; }
Example solution
[ 3-1 ]
Calculate 40÷13, and make the program that displays the expression, the quotient, and the remainder.
Example solution
[ 4-1 ]
In C language, when you do the dividing calculation by the integer
Though the result is rounded down when it cannot be divided
Explain it concisely why.
[ 1-1 ]
String literal
[ 1-2 ]
*
- It is read that it asterisks.
[ 1-3 ]
/
Problem
[ 1-4 ]
Floating point
Problem
[ 2-1 ]
- The dividing calculation of the integer notes that it is not a half-adjust but a round-down.
2
2.857143
- The decimal only has to be suitable for about the second place of the answer of the real number.
Problem
[ 3-1 ]
- Even if the sign of the remainder is different as soon as dividing, it is a correct answer.#include <stdio.h> int main(void) { printf("%d / %d = %d ... %d\n",40,13,40 / 13,40 % 13); return 0; }
- Though it is a correct answer when the expression is displayed as a character string
It becomes accustomed and I want it because it will multiuse the conversion specifier in the future.
- When it doesn't calculate, and the answer is made a character string, it is a wrong answer.
Problem
[ 4-1 ]
When you reversely calculate the number quotient × divided when rounding it off
Contradiction of largeness is caused from ....former.. drinking.. number that is [wari] as a result.
It makes it to the round-down because it becomes the origin of the miscalculation.