check50

cs50/problems/2022/x/cash


:) cash.c exists

Log
checking that cash.c exists...

:) cash.c compiles

Log
running clang cash.c -o cash -std=c11 -ggdb -lm -lcs50...
running clang cash_test.c -o cash_test -std=c11 -ggdb -lm -lcs50...

:( get_cents returns integer number of cents

Cause
expected prompt for input, found none

Log
running ./cash_test 0...
sending input 100...

:( get_cents rejects negative input

Cause
expected prompt for input, found none

Log
running ./cash_test 0...
sending input -10...

:( get_cents rejects a non-numeric input of "foo"

Cause
expected prompt for input, found none

Log
running ./cash_test 0...
sending input foo...

:) calculate_quarters returns 2 when input is 50

Log
running ./cash_test 1...
checking for output "2"...

:) calculate_quarters returns 1 when input is 42

Log
running ./cash_test 2...
checking for output "1"...

:) calculate_dimes returns 1 when input is 10

Log
running ./cash_test 3...
checking for output "1"...

:) calculate_dimes returns 1 when input is 15

Log
running ./cash_test 4...
checking for output "1"...

:) calculate_nickels returns 1 when input is 5

Log
running ./cash_test 5...
checking for output "1"...

:) calculate_nickels returns 5 when input is 28

Log
running ./cash_test 6...
checking for output "5"...

:) calculate_pennies returns 4 when input is 4

Log
running ./cash_test 7...
checking for output "4"...

:( input of 41 cents yields output of 4 coins

Cause
expected prompt for input, found none

Log
running ./cash...
sending input 41...

:( input of 160 cents yields output of 7 coins

Cause
expected prompt for input, found none

Log
running ./cash...
sending input 160...