🔒 Closed Ano mali dito

Status
Not open for further replies.

DOPEinDOPAMINE

Forum Guru
using System; private static void Main() { int x; int y; Console.Write("Enter input: "); string tempVar = ConsoleInput.ScanfRead(); if (tempVar != null) { x = int.Parse(tempVar); } y = x / 1000; Console.Write("\nNo. of P1000 bill: {0:D}",y); x = x % 1000; y = x / 500; Console.Write("\nNo. of P500 bill: {0:D}",y); x = (x % 500); y = x / 200; Console.Write("\nNo. of P200 bill: {0:D}",y); x = (x % 200); y = x / 100; Console.Write("\nNo. of P100 bill: {0:D}",y); x = (x % 100); y = x / 50; Console.Write("\nNo. of P50 bill: {0:D}",y); x = (x % 50); y = x / 20; Console.Write("\nNo. of P20 bill: {0:D}",y); x = (x % 20); y = x / 10; Console.Write("\nNo. of P10 coin: {0:D}",y); x = (x % 10); y = x / 5; Console.Write("\nNo. of P5 coin: {0:D}",y); x = (x % 5); y = x / 1; Console.Write("\nNo. of P1 coin: {0:D}",y); x = (x % 1); Console.ReadKey(true); }
 
Eto idok.
Screenshot_2022_1021_224421.webp
 
Status
Not open for further replies.

Similar threads

About this Thread

  • 1
    Replies
  • 388
    Views
  • 2
    Participants
Last reply from:
Ronalyn Magayon

Trending Topics

Online now

Members online
1,078
Guests online
834
Total visitors
1,912

Forum statistics

Threads
2,274,957
Posts
28,959,592
Members
1,233,493
Latest member
Alluneediswalk
Back
Top