// Arup Guha
// 8/30/2011 - COP 3223 Tappen's Section
// Illustrate the use of scanf

#include <stdio.h>

// This is how constants are declared in C 99.
const double COST_GAME = 59.99;
const double COST_SODA = 1.29;

int main() {

    int videogames, soda;

    // Get user information.
    printf("How many videogames are you buying?\n");
    scanf("%d", &videogames);

    printf("How many sodas are you buying?\n");
    scanf("%d", &soda);

    // Calculate the total cost.
    double total = videogames*COST_GAME +
                   soda*COST_SODA;

    // Output this cost.
    printf("You spent $%.2lf on games and soda.\n", total);

    return 0;
}
