1 00:00:00,000 --> 00:00:00,500 2 00:00:00,500 --> 00:00:01,590 ZAMYLA CHAN: Hello, world. 3 00:00:01,590 --> 00:00:02,570 My name is Zamyla. 4 00:00:02,570 --> 00:00:06,670 And I will be your walk-through lead for these CS50 problems. 5 00:00:06,670 --> 00:00:10,160 In each walk-through, I'll go for what's required for the problem, 6 00:00:10,160 --> 00:00:13,360 I'll go over what the list of to-dos are, 7 00:00:13,360 --> 00:00:17,840 and I'll provide more of a high-level, algorithmic way of getting started, 8 00:00:17,840 --> 00:00:20,050 give you a few hints, a few snippets of code. 9 00:00:20,050 --> 00:00:24,350 And hopefully, you'll be well on your way to completing the problem. 10 00:00:24,350 --> 00:00:26,860 >> So for today, let's talk about hello, where 11 00:00:26,860 --> 00:00:29,930 we're going to write our very first C program. 12 00:00:29,930 --> 00:00:33,070 What we need to do is first navigate to our workspace, 13 00:00:33,070 --> 00:00:38,530 where we're going to create a file and save it as hello.c. 14 00:00:38,530 --> 00:00:41,220 I've already written a bit of code already. 15 00:00:41,220 --> 00:00:44,060 I've included the standard io library, and then 16 00:00:44,060 --> 00:00:46,760 I just created my main function. 17 00:00:46,760 --> 00:00:53,410 >> What I'm going to do is I'm going to write printf Hello, world! 18 00:00:53,410 --> 00:00:57,710 with a backslash n for a nice, new [INAUDIBLE] formatting, 19 00:00:57,710 --> 00:00:59,910 and a semicolon to end. 20 00:00:59,910 --> 00:01:02,260 After saving our program, let's go to our terminal, 21 00:01:02,260 --> 00:01:07,430 where we're going to compile it by typing the command make hello. 22 00:01:07,430 --> 00:01:08,590 It compiles correctly. 23 00:01:08,590 --> 00:01:13,550 And so we can go ahead and run our executable file ./hello. 24 00:01:13,550 --> 00:01:15,900 >> And there we get Hello, world! 25 00:01:15,900 --> 00:01:16,880 Hello, world! 26 00:01:16,880 --> 00:01:20,910 My name is Zamyla, and this was hello. 27 00:01:20,910 --> 00:01:22,151