You are on page 1of 5

Degree of Bachelor of Information Technology ITE 1112 – Visual Application Programming

Faculty of Information Technology


University of Moratuwa

Degree of Bachelor of Information Technology (BIT)External

ITE1112: Visual Application Programming – Activity 7

Learning Objectives: Understand remainder operator

Question 1:

Write program enter your salary amount in rupees prints the number of,
1000/=,500/=,200/=,100/=,50/=,20/=,10/=,5/=,2/=,1/= notes and coins needed.
E.g.: - Amount=2754

Your program should print as follows

1000-Notes-2

500 Notes-1

100 Notes-2

50 Notes-1

20Notes-0

10 Notes-0

5Notes-0

2Notes-2

1Notes-0

Hint: -

 1000 Rupee notes=2754/1000=2


 Remaining Amount =2754%1000=754
 You need to use suitable variables.
Initial Interface
Answer

1. Create interface as follow using Text box, Data Grid View and button.
2. Submit button click event.

 Here you need to use integer type array and enter notes and coins available in Sri
Lanka.
 After that using for loop and using Reminder operator (%) Or Modulo (%) you
can calculate the notes and coins included in your salary as follow.
3. Final output should be as follow.

You might also like