※スタイルシート未対応ブラウザではレイアウトを正確に再現できません。
  > | advanced by | contents  | that returns in <    
                   < [modosusu] > Color magazine monochrome light and shade   font predetermined, Gothic Ming-style type longhand   size Konaka large   standard  


  Exercise 5   

  1. ..clause 1..: Basic knowledge
  2. ..clause 2..: Program readout
  3. Memo
  4. ..clause 4..: Description type
  5. ..clause 5..: Basic knowledge(example solution)
  6. ..clause 6..: Program readout(example solution)
  7. Memo(example solution)
  8. ..clause 8..: Description type(example solution)

[1] Basic knowledge


[  1-1  ]
What is called naming the name to the memory that memorizes the numerical value?

[  1-2  ]
What is called the memory of the numerical value in the above-mentioned place?

[  1-2  ]
What is called only one expanding the numerical value of the above-mentioned place?
Example solution

It returns to contents.


[2] Program readout


[  2-1  ]
How are you displayed when the following program is executed?
 
#include <stdio.h> 

int main(void)  
{
	int x,y;  
	
	x = 10;  
	y = x * 10 + 20;  
	printf("%5d\n",y);  
		
	return 0;
}
Example solution

It returns to contents.


Memo


[  3-1  ]
Buy one soft drink of 198 yen each and 2 glasses of milk of 138 yen each.
Request fishing when it pays by the thousand yen bill.
However, the consumption tax of 5% is added, and the fished amount is assumed to be an integer.
It is assumed whether the half-adjust of the consumption tax to be free.
Example solution

It returns to contents.


[4] Description type


[  4-1  ]
3.14 * When calculating as 12 according to the real number and the integer
Describe the reason concisely though the answer is treated as a real number.
Example solution

It returns to contents.


[5] Basic knowledge(example solution)


[  1-1  ]
Variable declaration
- Even only the variable is a correct answer.

[  1-2  ]
Substitution

[  1-3  ]
Increment
Problem

It returns to contents.


[6] Program readout(example solution)


[  2-1  ]

  120
- The space of two digits enters the previous part because it is %5d specification.
Problem

It returns to contents.


Memo(example solution)


[  3-1  ]
 
#include <stdio.h> 

int main(void)  
{
	int juice,milk,money,payment,change;  
	double tax;  
	
	juice = 198;  
	milk = 138;  
	money = 1000;  
	tax = 1.05;  
	
	payment = (int)((juice + milk * 2) * tax);  
	change = money - payment;  
	
	Printf ("%d yen \n" change);  
			
	return 0;
}

503 yen
- The change is easy later though you may not use the variable and solve it if it uses it.
- When the casting conversion has been forgotten, it is assumed that it gives a demerit mark.
- When the answer is made a real number, it is assumed that it gives a demerit mark.
- The answer is slightly different according to the computational method.
Problem

It returns to contents.


[8] Description type(example solution)


[  4-1  ]
To prevent the numerical value below the decimal point being rounded down.
Problem

It returns to contents.


< - It is advanced -> | in | head that returns  to returning  next |.