


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



Q# 01: Write a program which accepts amount as integer and display total number of Notes of Rs. 500, 100, 50, 20, 10, 5 and 1. For example, when user enter a number, 575, the results would be like this... 500: 1 100: 0 50: 1 20: 1 10: 0 5: 1 1: 0 #include
h=g/20; cout<<"the number of 20 notes is = "<<h<<endl; i=g%20; j=i/10; cout<<"the number of 10 notes is = "<<j<<endl; k=i%10; l=k/5; cout<<"the number of 5 rs. coins is = "<<l<<endl; m=k%5; n=m/1; cout<<"the number of 1 rs. coins is = "<<n<<endl; return 0; }