The problem with these CS50 homework is that they always require some extra knowledge that didn't teach in class😂 Thank you! You helped me a lot!
@e.telizondotavernier4232 Жыл бұрын
fr like wtf lol
@LifeLongArtist Жыл бұрын
there are practice problems on the bottom of the list that gives you the notes and slides before you watch the presentation
@RiddhiiSharma Жыл бұрын
For sure 😂
@justarandomguy-gn2tu10 ай бұрын
bump into small problems on the way, do a bit of research on your own to find out how to solve them - that's the way of life not only just programming my guy 💪
@sinless10 ай бұрын
Yeah seriously. They expect us to use the round function without ever teaching us that it even exists...
@sangois912 жыл бұрын
I just want to let you know that you are helping people everywhere, I'm Brazilian, and today, I came to say thank you for these videos. The way you explain make me see the problem from other point of view. Thank you, please don't stop with these videos
@MrAv3rag32 жыл бұрын
Disse tudo. Brazil appreciates it!👏👏
@cortesnalata2 жыл бұрын
@@MrAv3rag3 very good kkkkk
@felipefigueiredoavelar2 жыл бұрын
kkkkk eu também
@artico1664 Жыл бұрын
ih rapaz eu n to sozinho kkkk
@williamkenzo38252 ай бұрын
me too kkkk. terminaram o cs50? como foi? did NOT expect finding some home boys over here.
@thecryptobeard2 жыл бұрын
Thanks bro, when I started I kept having to rewind. Now I'm actually pausing because I know the answer and am finishing before you get done explaining. Awesome job my man!
@bawnix47007 ай бұрын
so you're telling me it gets better because holy crap its humbling, it feels like im trying to learn how to walk again.
@setagangastudios5742 жыл бұрын
You helped me see something that was so plainly obvious just by looking at it logically instead of programmatically. Definitely earned my sub!
@ashmitmishra3 жыл бұрын
Big brother, the way you explain the topic, it feels like I have subscribed a online course by paying some amount.
@CS50MadeEasy3 жыл бұрын
Haha, thanks man. Means a lot!
@artyomd88422 жыл бұрын
Hi, thanks for the video. Actually the CS50 instruction said we had to do all the letters/words/sentences counting through the separate functions, and not inside the main. I suppose they want us to get used to handle functions properly. Also, correct me if I'm wrong, but your expanded code for counting letters has some mistakes. You made it: "if text[i] > 65". But this won't include 'A' because 'A' is 65. It's not grater than 65, it's 65, so it should be "if text[i] >= 65". Same with "less than 122" it won't count "z".
@e-d-ig.c24172 жыл бұрын
faca um video, existem poucos videos voce parece saber o que esta falando e eu preciso de ajuda kkkk
@hokaloah1002 жыл бұрын
This was the last big mistake I found in my project. Once I figure it out my code worked perfectly
@abdullahshahzad3332 жыл бұрын
Dude my head was about to explode. Thank you so much. You are a savior
@Xatraris8 ай бұрын
That explains why my scrabble was slightly off. I went ahead and used the isupper and islower parts in the library to fix the problem. Was just trying to figure out why. Thanks!
@gamingwithgeko73772 жыл бұрын
I get the concept of coding but I'm having trouble remembering the rules and building blocks. But I'm sure if I continue to put in as much effort as I did learning all the tedious physics in several video games, I'm sure I can get this too... so I can make video games haha. Thanks so much these tutorials help allot and I'm constantly pausing, replaying, and practicing with the video off. I mostly just wanna make it all the way through this course as thoroughly as I can and then move on to actually learning C# so I can make games and probably html or python so I can make side money in the mean time. Really looking forward to the future, thanks again.
@jakekayden4061 Жыл бұрын
Hey, did you keep learning?
@rikkiwebber3200 Жыл бұрын
The for loop can also be written like this using the ctype header file. for (int i = 0; i < strlen(text); i++) { if (isalpha(text[i])) { letters++; } else if (isspace(text[i])) { words++; } else if (ispunct(text[i])) { sentences++; } }
@muraliks8617 Жыл бұрын
Truly appreciate you taking time to upload these videos, it is very clear and simple. Thank you!
@its_seabass96682 жыл бұрын
Just wanted to mention that I tried checking it with the original equation (without the isalpha function) and had several errors. But as soon as I added it everything went away. Definitely a nice tool to have
@velenvskaelhas2 жыл бұрын
Also if you read the specification on the CS50 site it does let you know what you'll need.
@ahmadaltahan77452 жыл бұрын
Make sure you include 65, 90, 97, and 122 by using >= and
@bmagaziner Жыл бұрын
@@ahmadaltahan7745 thank you, this made me want to strangle him while i watched
@mohammedel-hayek33832 жыл бұрын
A friend of mine has recommended me this tutorial. And i couldn't' be more happier
@NintendoFanatic212 жыл бұрын
holy crap. you know your stuff! i havent seen this so easily demonstrated anywhere!
@leongrundmann18462 жыл бұрын
Thanks for the helpful video! Helped me to solve the problem set. I just paused when I knew what you said, so I could still try to solve the problem on my own, using your video just when I was completely lost
@houston74972 жыл бұрын
I love the way you explain the logic in your videos. Hope you continue to make some more videos!
@ciaranbusiness3 ай бұрын
Brother you help me bridge the learning gap between lecture and assessments. God bless you.
@parzgodedits7 ай бұрын
Man, you are a life-savior. Thanks a lot
@FranklynAgbeko6 ай бұрын
thanks, a lot from the beginning things looked a bit difficult but watching your videos makes me feel I can do it. once again thanks you are a chap you should consider teaching 🙏🙏🙏🙏
@karimanajim6286 Жыл бұрын
omg thank you sooo so much, I was having a lot of trouble understanding this but you explained it all so well, you are such a good teacher, keep going!!!
@ali-xperia717 ай бұрын
Thanks a lot! even two years later this is very helpful! I might buy you a coffee some day!
@hokaloah1002 жыл бұрын
Thank you again, so much for these videos. I'm happy to say that I only needed this video to prod me in the right direction a few times. My code definitely isn't as pretty as yours, but I did write it mostly by myself. There were even a few times when I was stuck and checking with this video, and as soon as you said, "let's think it through logically," it was like a light bulb would go off in my head and I'd fix my problem before seeing what you did.
@grich__2 жыл бұрын
When using the original code to find out how many letters there are be sure to add an equal sign (=) to your less than and greater than signs (< , >) they should read as follows.......[ text[i]
@PeterDee-m2q10 ай бұрын
Thanks Rahul for your work in explaining the code walk through for the Readability exercise. The conditional if statement for printf helped me to better design my solution. Peadar - Ireland
@theinhtite96962 жыл бұрын
Brother your video is a saint. Thank you for explaining what my dumb brain could not.
@a88pockets Жыл бұрын
Thanks for the video. Between your tutorials and Dors' channel I'm really starting to get this stuff. In fact I had created the bones of a program before digging into your tutorial with 3 functions calls for int letters, int words, int sentences...from these functions: int numLetters(string text); int numWords(string text); & int numSentence(string text); and after watching and completing the tutorial your way with every thing calculated under the main function and then I completed it my way with 3 functions. Longer than necessary but I was pretty pumped that I understood the material enough to solve in another fashion.
@brandongreen5790 Жыл бұрын
Errors in your code: @ 7:18. You would have to change the ">" and "=" and "
@salmasameh50712 жыл бұрын
Really thank you for your effort , you are helping me a lot to understand these problems, keep going you are awesome
@LilDrummaDude8 ай бұрын
You are a legend my friend!
@karimal-mufakkir404111 ай бұрын
Man, you are an angel ❤
@stuff98932 ай бұрын
Thank you, man! Really helpful
@jerrianbrooks26592 жыл бұрын
Definitely subscribed...you have been a lifesaver through this course!!!!!
@Damonbodine Жыл бұрын
Super appreciate this video. Thank you.
@clevebissoon23542 жыл бұрын
Excellent stuff mate. None better than you.
@ChonpsScene Жыл бұрын
Hey man, thanks a lot. I did part of the code correctly, but when I start doing the math count the program doesn't want to work, but with this video you give me a light.
@matiasroj02 жыл бұрын
thank you very much, i love the way you use logic to solve these problems
@NaturesTide Жыл бұрын
Your great at explaining things. Thanks a lot for taking your time to make this video.
@365472 жыл бұрын
wonder why he stopped making these? hopefully they didn't tell him to stop posting. He provides this in a very logic way for people
@CS50MadeEasy2 жыл бұрын
Just been really busy, I'll try to start uploading consistently soon :)
@aliyusuf7959 Жыл бұрын
Thanks for making this video bro. Helped me out a lot !
@dustinhxc2 жыл бұрын
Thank you so much for your explanations! Love your Logic!
@shahriyarm6632 жыл бұрын
One the handsome and good indian man I've ever seen 🔥♥️ Your explanation is good too!
@becs_forlife7 ай бұрын
A week hitting my head into the wall trying to code this thing 😂😂😂😂 thank u 💞
@sergeantargentmrg3155 Жыл бұрын
At 8:54 you need to do >= &
@penadine2 жыл бұрын
Thank you, the clever boy! I love you!
@quentinnilsen53563 жыл бұрын
Great thoughts on this task! Please keep going🙏🏻🙏🏻
@1d_4e32 Жыл бұрын
thank you so much man!!!
@esraashahien34672 жыл бұрын
The casting part was very helpful thank you :)
@darthayala38322 жыл бұрын
"I'm going to post videos every single week" disappears for a month. WE NEED YOU BRO!
@CS50MadeEasy2 жыл бұрын
Caesar coming today! :)
@fiow49722 жыл бұрын
wow even iam not understand english buti really understand everything : ) ty bro
@lawimms21543 жыл бұрын
Thank you SO MUCH!
@CS50MadeEasy3 жыл бұрын
You're welcome!
@YashPatel-xq5bh Жыл бұрын
Hey , Can you tell me where you get the problem discription / specifications of problem doc file ? Or can you share the these doc files of problem sets .
@Music-Books Жыл бұрын
Just a quick question about how you were doing the ASCII evaluation prior to replacing all that with the isalpha function. Why wouldn't the evaluation be '> 64' and '< 123' to make sure that the letters A and Z were included?
@kareemziada65543 жыл бұрын
Amazing job u do really All love ❤️🙏🏻
@andresvillalba2012 Жыл бұрын
Thx for step to step, I mean thank you for time
@AlejandroDeLaRosa052 жыл бұрын
Thank you so much for all your content!
@MarySkywalker92 жыл бұрын
Thank you! Your explanation was very helpful
@artembelov59972 жыл бұрын
The problem of counting spaces is that if there punctuation marks like hyphen it will count it as a word. For example: "strlen - calculate the length of a string." Your program will give the answer 8.
@rumibhakar Жыл бұрын
thats why i just changed my value to 1 idk i tried a lot to fix it but this was the only solution that came to my mind
@zelimss Жыл бұрын
Thank you man!
@GilVanDerGraaf2 жыл бұрын
What a great video. Thanks a lot.
@ashmitmishra3 жыл бұрын
Brother olease continue this series.
@CS50MadeEasy3 жыл бұрын
That's the plan!
@alicjakopinska3342 жыл бұрын
@@CS50MadeEasy why did you lie!! We need you
@A-Karim20035 ай бұрын
by the way, you dont need to know the ascii value of any letter when checking, Your loop could look like this: if ((text[i] >= 'A' && text[i] = 'a' && text[i]
@guilhos78229 ай бұрын
I don't understand why they put exercises without arrays on a module/section called ARRAYS. I wasted prob 3 hours thinking about this exercise using arrays, calculating de average of letters in 100 words and stuff like this, to just come here and see how easy is this. Thank you, brother
@Combatereak4 ай бұрын
It’s because you’re using the other half of the lecture, where you manipulate strings like they’re arrays. You don’t explicitly need to create an array for this like you do with scrabble
@ahmedsanosy13542 жыл бұрын
bro ur genios
@AcerSwizz2 жыл бұрын
bro u are so smart, just the way u approach the problem makes me feel dumb. I was using the is alpha and isspace function setting the initial word count to 1.
@dsmode7 ай бұрын
Thank you so much!!!
@donbotanello Жыл бұрын
Thank you sensei
@moeketsimchunu48332 жыл бұрын
I'm from south africa thanks for you help, you simplified everything from pset1 . i salute you
@oluwatunmiseesther88322 жыл бұрын
You are the best Thank you
@ChristopherCalderonChrisCalder Жыл бұрын
Thank you, I didn't think about initializing the word count to 1 instead of 0 and it wasn't working for me.
@josephdaly20413 ай бұрын
When you do the loops around the 8 minute mark, aren't you excluding z and Z by not including a "
@nemanjam62723 жыл бұрын
Thank you for great work! Can you please explain how to implement this as a function "count_letters"?
@Vladimir-ey7to2 жыл бұрын
In case someone else needs the answer: create a prototype function int count_letters(string text); and put it before int main(void). Type the same thing, but without the ";" after int main(void), put a pair of those { } and inside of them "explain" what the function does (how it counts letters), by using the technique shown in the video. just remember to use return letters; before the final }. The final step is to tell int main(void) to use the function and count the number of letters, for example letters = count_letters(text);
@emmanuelayisi14922 жыл бұрын
int count_letters(string letters) { int letter_count = 0; for (int i = 0; i < strlen(letters); i++) { if (letters[i] != ' ' && isalpha(letters[i])) { letter_count++; } } return letter_count; }
@nicholasmoleta25952 жыл бұрын
Thanks for the content. You explain things super clearly
@yotayworldtv Жыл бұрын
Thanks so much
@YashPatel-xq5bh Жыл бұрын
Thanks Your videos help a lot 👍(scratch game video helps in start point ).
@hadou54832 жыл бұрын
thank you!!
@RASELX9 ай бұрын
Bro can we use chat gpt for help or even copy some the code? Will they knows?
@brandongiordano79232 жыл бұрын
What's the purpose of the two equals signs on line 22?
@SirRunningwolf2 жыл бұрын
Good lesson)!
@doragondsu35872 жыл бұрын
i feel soo dumb rn....i was using "=" insted of "==" and......thats it i fell sooo fucking dumb lmaooo greatings from brazil really helped man
@Music-Books Жыл бұрын
for the float L and float S calculations ..... are we assuming that the division is going to always happen first because of the temporary float status of the variables letters and sentences? Or does it really matter? Thx.
@kartikyadav57042 жыл бұрын
How are you able to figure out all these and present them in such an easy way? Though, Hats Off to you...
@mahdiardforosh67352 жыл бұрын
HI,when you are going to upload th other problem sets ?
@heileychan4910 Жыл бұрын
Thank you very much for a video! I have a quick question thou: for line 27, can I represent the punctuations(. ! ?) using their ASCII values(33, 46, 63)? Thanks!
@hassanabdel-twab7375 Жыл бұрын
yes, you can. i used their ASCII values and it worked.
@heileychan4910 Жыл бұрын
@@hassanabdel-twab7375 thanks a lot!
@a-creations37582 жыл бұрын
I wrote it and it compiles and everything but when I try a sentence it says segmentation fault (core dumped)
@yskthegamer90332 жыл бұрын
We're you able to fix it ?
@karimashraf-mb5wb2 жыл бұрын
thanks i make the functions and all thing but did something wrong as you when i enter integer into float without casting and when i was debuging every thing right in the equation but the result was wrong untill i make casting to the integer so thank u
@rebecasantamariavillar91162 жыл бұрын
thank you!!!!
@DEEPTSHOP2 жыл бұрын
There was actually an error. Should be: if ( index > 15) or if ( index >= 16)
@anonymousani5052 Жыл бұрын
when i use (float) in both words, the values get rounded down, so the grade stays lower than it shoulda
@Danielsan1223 Жыл бұрын
I'm pretty sure I wrote everything you wrote, but when I have the results print out like "Before Grade 1" it prints out that phrase several times. Why is it doing this? I've tried and tried to get it to just print the results one time but it won't do that for some reason.
@stora_simon63862 жыл бұрын
MAN I FKN LOVE YOU, iDK IF IM RETARDED BUT I WOULD NOT BE ABLE TO SUBMIT ANY OF THESE CODES WITHOUT YOU. THX (=
@maishamohomed3076 Жыл бұрын
can you tell me why in the loop text has () brackets and in the isalpha text[ i ] has a square bracket?
@Syneptic2 жыл бұрын
Doesn't work.
@RuthYu.63 Жыл бұрын
Hi, I am Ruth! Thank you for your video. I have a question regarding definiting letters. I tried both the "c language" way and the "isalpha" function but the results were different. When using the "isalpha" function the grade is correct. However when I use the original way the grade is always 3 grades less than expected. Do you have any idea why this happens? Thank you!
@rebekahmenn21182 жыл бұрын
Quick question (I hope this makes sense): at the very end of the code where we have the "if (index < 1).... else if (index >16) ... else..." When I was creating my code, I initially made two "if" statements: "if (index < 1) ... if (index > 16)... else..." I didn't use "if" "if else" "else." And for some reason, when I use the code "if (index > 16)... that affect my output for sentences below grade one. It would tell me "Before Grade 1. Grade -7." I'm curious why changing the "if else" statement which corresponds to levels ABOVE grade 16 would affect the output for levels BELOW grade 1. I checked several different sentence levels using "if" "if" "else" (instead of the proper "if" "if else" "else") and it only affected the results for below grade 1. Any insight would be greatly appreciated. Thank you for this video! I found it incredibly helpful!
@moa96402 жыл бұрын
i had this same issue, the second if is not "if else", it's "else if" that fixed mine
@MorphTW2 жыл бұрын
It seems like i have a rounding problem. i pass around 50% tests and fail the others with 1 grade difference.
@VDViktor2 жыл бұрын
Everything here is done in main. In CS50 manual all three functions are declared separately, and as i try to code them each separately - it all gets messed up for some reason.
@CS50MadeEasy2 жыл бұрын
There's more than one way to solve the problem sets. I did it the way I found to be the most understandable. You can choose to do it with functions as well if you'd like. :)
@siaralamex2 жыл бұрын
did you try do step by step? I just found the way to print the number of letters, we'll se if I am able to solve the rest ;)
@mathewmphilip97752 жыл бұрын
I am getting segmentation fault (core dumped) when doing count_sentences...could anyone help
@yskthegamer90332 жыл бұрын
We're you able to fix it ?
@maxim55192 жыл бұрын
if I understand right for grade 16 + and 16 itself code supposed to be like this (more or equal): else if (index >= 16) { printf("Grade 16+ "); } not just (more): else if (index > 16)
@jamesolgen Жыл бұрын
youre crazy man, you code on light mode, ahahhahahahhaha, great tutorial, thanks
@davidwds2 жыл бұрын
thanks man!\
@Rohit47922 жыл бұрын
hello friend ?? can you tell me if this program also works on iPhone 7 Plus with iOS 15.4 ??
@Allin1Xavi2 жыл бұрын
What would change if float index is implemented instead of int index? What’s the difference? Wouldn’t that be better since we need to round to a whole number to calculate a grade level? Or is the calculation itself a decimal and we just ask the program to print a whole number, unless the value is less than 1? I just want to be sure I’m right and not try to overthink it bc I’m still fairly new to this.
@15emranlutfi9 Жыл бұрын
when you add for example 1.4 + 1.3 = 2.7 , it will round up to 3. However, if you add them as integers you will get 1+1 =2.