Bài 1: Declare two variables x and y. Assign values to these variables. Number x should be printed only if it is less than 2000 or greater than 3000, and number y should be printed only if it is between 100 and 500.
Flow Chart:
Final result:
Flow Chart |
My Code |
Final result:
Bài 2: Write a program to show your computer’s capabilities. The user types in a letter of the alphabet and your program should display the corresponding language or package available. Some sample input ans output is given below :
Input Output
A or a Ada
B or b Basic
C or c COBOL
D or d dBASE III
f or F Fortran
p or P Pascal
v or V Visual C++
No comments:
Post a Comment