View Single Post
Old 02-05-2007, 11:28 PM   #11 (permalink)
redhead
Newbie
 
redhead's Avatar
 
Join Date: Jun 2002
Location: Denmark
Posts: 1,720
redhead is on a distinguished road
Alright, here is the missing code to this one:
Code:
    std::cout << "Quarters:\t" << amount/25 << std::endl;
    amount = amount %25;
  }
  if(amount >= 10){
    std::cout << "Dimes:\t\t" << amount/10 << std::endl;
    amount = amount %10;
  }
  if(amount >= 5){
    std::cout << "Nickels:\t" << amount/5 << std::endl;
    amount = amount %5;
  }
  if(amount >= 1)
    std::cout << "Pennies:\t" << amount << std::endl;
  return 0;
}
__________________
Don't worry Ma'am, We're university students, We know what We're doing.
-----
If you pull the pin, Mr.Grenade would no longer be your friend.
-----
01000111 01101111 00100000 01000011 00100000 00100001
redhead is offline   Reply With Quote