Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

4th March 2019

Program Kecemerlangan Akademik Sains Komputer


Semester 2, Sesi 2018/ 2019

1. Create a program that converts US Dollar to MYR (Malaysian Ringgit). Hint: RM1 = $ 0.31.

a) Analyze the problem statement by identify input, process and output.


b) Write a pseudocode and flowchart
c) Write a java program for the algorithm.

2. Create a program that prompt the user to choose either US Dollar or Brunei Dollar to convert
MYR (Malaysian Ringgit). The currencies and exchange rates are listed in the table below.
Hint: (Hint: Designate a code for each currency).

Currency Exchange rate


US Dollar 0.31
Brunei Dollar 0.39

a) Analyze the problem statement by identify input, process and output.


b) Write a pseudocode and flowchart
c) Write a java program for the algorithm.

3. Create a program that converts MYR (Malaysian Ringgit) to a different currency. The currencies
and exchange rates are listed in the table below. The user should be allowed to choose the
currency. (Hint: Designate a code for each currency).

Currency Exchange rate


US Dollar 0.31
Brunei Dollar 0.39
Singapore Dollar 0.39
Thai Bath 9.88
Indonesian Rupiah 3493.13

a) Analyze the problem statement by identify input, process and output.


b) Write a pseudocode and flowchart
c) Write a java program for the algorithm.
4th March 2019

4. Create a program that converts MYR (Malaysian Ringgit) to a different currency. The currencies
and exchange rates are listed in the table below. The user should be allowed to choose the
currency. (Hint: Designate a code for each currency). The program will run for 10 users.

Currency Exchange rate


US Dollar 0.31
Brunei Dollar 0.39
Singapore Dollar 0.39
Thai Bath 9.88
Indonesian Rupiah 3493.13

d) Analyze the problem statement by identify input, process and output.


e) Write a pseudocode and flowchart
f) Write a java program for the algorithm.

5. Create a program that converts MYR (Malaysian Ringgit) to a different currency. The currencies
and exchange rates are listed in the table below. The user should be allowed to choose the
currency. (Hint: Designate a code for each currency). The program will be repeated
continuously and it will stop when the user enters Z for the currency code.

Currency Exchange rate


US Dollar 0.31
Brunei Dollar 0.39
Singapore Dollar 0.39
Thai Bath 9.88
Indonesian Rupiah 3493.13

g) Analyze the problem statement by identify input, process and output.


h) Write a pseudocode and flowchart
i) Write a java program for the algorithm.

You might also like