diff options
author | Fudgerboy <91767657+Fudgerboy@users.noreply.github.com> | 2023-12-01 05:35:48 +0000 |
---|---|---|
committer | Fudgerboy <91767657+Fudgerboy@users.noreply.github.com> | 2023-12-01 05:35:48 +0000 |
commit | b2453faff43249953dddf17d04b46a9ea201c804 (patch) | |
tree | 7dd818bdbb0255f42cd37335a18cba2aa4006afb /agree.c | |
parent | 6c239dc828d73b974b51109db65765beaca4a354 (diff) |
Thu, Nov 30, 2023, 9:35 PM -08:00
Diffstat (limited to 'agree.c')
-rw-r--r-- | agree.c | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -0,0 +1,15 @@ +#include <stdio.h> +#include <cs50.h> + +int main(void) +{ + char c = get_char("Do you agree? "); + if (c == 'y') + { + printf("Agreed.\n"); + } + else if (c == 'n') + { + printf("Not agreed.\n"); + } +} |