Love MIT for their CS OCW!!! One comment to add here. When you ask Python to compare two strings (like mentioned in the video "a" > "b" and the result is False) in the backend, Python is comparing their ASCII values (ASCII value of "a" = 97 and ASCII value of "b" = 98. Hence False)
@@r4ko276String equality checks if two strings have the same contents. Checking if a string is greater than another string (string inequality) checks if the first string comes after the second string if you were to sort them alphabetically.
Kind of wish I got to experience CS at MIT. I loved my professors but this is a professor I know I'd like and learn alot from. Plus MIT's reputation is unmatched.
Same, except for me it would've been math/statistics. MIT was the only school I couldn't get accepted into (it was my dream school as a high school student). Having access to this open courseware in my 30s gives me a chance to check some of it out (just in a different subject).
I am very lucky and happy to see the smiley ,energetic and enthusiastic face of ANA mam ,when she tried to listen the question that the student asks.BUT AT OTHER PLACES , THIS HAPPENS RARELY BUT NOT IN MIT.
Me and a fellow colleague are leaping into Python (my native language being R). The lecture videos are well-paced and the lecturing style is top notch! I lecture the occasional statistical programming course, and it's not always easy to keep it interesting and engaging like it is here.
For those curious about how Dr. Bell commented out certain lines of code here's the shortcut list, Single line comment Ctrl + 1 Multi-line comment select the lines to be commented Ctrl + 4 Unblock Multi-line comment Ctrl + 5 P.S: Got this from Stack Overflow so due credit to the actual authors for this query.
Had somebody taught flow control statements as clearly as Dr.Bell my coding journey would have been at stratospheric levels...these lecture ignited my hopes of becoming a good programmer...
Dr. Ana Bell is great teacher.❤❤❤ You are very good at explaining and in all perspective. You are best.Thanks MIT for Dr. Ana Bell. Thanks MIT for OCW.MIT is best and doing great work.
The idea behind ocw is profound. By distributing knowledge to the whole world for free, MIT is paying tribute to the geniuses like faraday, curie, ramanujan etc... Who produced phenomenal works despite of not having the proper access to the knowledge they needed.
38:54 both codes ARE WORNG SHOULD BE for i in range(5, 11, 2 ): print(i) NOT LIKE : x = 0 for i in range(5, 11, 2 ): x += i print(x) I get output : 21 with that code for some reasons
Excellent lecture. Makes me wish I were back as a student. this is the best explanation of for & while loops I have seen. I wish I could take this course, but I no longer live in Boston.
Regarding range(stop,start,step) 40:30: Normally num-1, but in this case, we're going to the end minus "two". (num - 2). I came across a component of this topic on stackoverflow, where someone described the end of the range as "minus two", which left me puzzled, so I thought I'd post.
Python always has the extra +1 whenever there is a range. This is different if you come from other programming languages but once you get used to it it will not bother you. Also true when slicing a string. For example: # 1 1 1 # 0 1 2 3 4 5 6 7 8 9 0 1 2 a = "hello, world!" # h e l l o , w o r l d ! b= a[1:8] print(b) # output # ello, w
@@mvisperas In the case of range(5,11,2) From five up to but not including 11. It went 5...7...9 It stops at 9, and She says "...So we're going to the end MINUS ONE...." But actually it's going to the end, MINUS TWO. But I still agree with your comment. Normally, if it were range (5,11), with one hop as the default, it would be getting to the end (11) minus one. It was just a small thing, but thought I'd mention it. Yes, I see how you're thinking.
Another example: Two hops. It goes to the end "minus two". for num in range(6,26,2): print(num, "", end="") 6 8 10 12 14 16 18 20 22 24 I also tried to index a range, but you have to change it to a list first because range is immutable. Range 20 up to, but not including, 50. Two hops. So up to the end "minus two". range_2 = list(range(20,50)) print(range_2[0:30:2],"", end="" ) [20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48]
@@algemmegla9002 The end value is always the highest value without being equal to or exceeding the stop value - you can treat it as always less than. This statement is true whether the step value is 1, or 2, or 3, or whatever step value you choose. Thus if you do range(5, 11, 3) then the count is 5 ... 8. It won't do 11 as it is equal to the stop value.
@@mvisperas I understand. Whatever is equal to the stop value gets ignored. I think we're both saying the same thing, but we're just wording our examples differently. As you mentioned in your example, you could say it stops at 11 because it is equal to the stop value, "and" you could also say it goes up to the end "minus two" (or 8) We're both saying the same thing. It's just different ways of explaining the concept.
I want to ask a question not related to syllabus but a great tips Dr. Ana Bell used in this lecture, Lecture No 2(Branching and Iteration) and I have question in Time:39.48/43.30.... Here Dr. Ana used a great tips: She just select some sort of lines and deleted the "#" sign in a single moment.... I want to know how can I do it the same thing on Spyder.... Please comment to me... If you know please give me suggestion... Please Please.... (From INDIA)
to improve examples e.g. for string print( "you_can", "show", "where_the_spaces_are_added", "!" * 3 ) the example code blocks could have a colored background or have a colored border
32:21.... y no n += 1?? also loving the Corse so far, did problem sets 0 and 1a before watching this, would love to go to MIT at some point in my life to get a Comp sci degree
It would help that when Ana points to the board and makes a comment, the camera also shows the board and not the picture of Ana talking. thanks for the free lectures
"b" is greater than "a" because __lt__ / __gt__ methods of the string class were made to convert the characters to ascii values and return the comparison of those values?
Anaconda allows intereacitivty: IPython + Spyder (inspire on Matlab, (Matplotlib),+ support for other languages like ruby, R, Julia, Haskell ....etc. wow I am going to explore that tomorrow...
how do you remove the # from multiple lines in spyder? whats the hotkey. theres probably also a hotkey to a add it. so comment/ uncomment selected lines. like at 39:48
For the while main_condition: while sub_condition: expression_a() break # This break always happens expression_b() # This will never execute expression_c() What is the point of having expression b if it will never execute?
I asked same question.... Even I don't know how she can able to do it... By looking at her screen view I think she uses Windows Machine... Please brother if you get your answer please reply to me also....
If you're using an IDE like Spyder, here's the shortcut key to it, Single line comment Ctrl + 1 Multi-line comment select the lines to be commented Ctrl + 4 Unblock Multi-line comment Ctrl + 5 P.S: Got this from Stack Overflow so due credit to the actual authors for this query.
The 'if' nested in an 'if' would only be considered if the parent 'if' is true, the 'else' nested in that won't ever be considered, then why use it at all? Also if all the nested 'if's have same condition during nesting then if they are true, it'll execute them all at once, so what is the use of that? What we want is that it asks us the question and show us the forest screen until we enter a 'left', so what we want it to do is to repeat this 'if' condition again and again so that it asks us that question again and again X=input (" left/right..?") If x== "right": Else: How can we do that? I didn't understand the need for while here, because for it to ask us the same question again an again we will have to run this code again and again, and that can be done with an 'if-else' condition as well.
We used a while loop because we don't know how many times the user will enter right. x = input (" left/right..?") If x== "right":
Else: will take the input only once. What if I want to go right twice? Let's say, you use 7 nested if statements, the program would ask the user for direction 7 times. Not more, not less. What if I want to go right 10 times? I wouldn't be able to. Notice the condition of her while loop. It doesn't matter whether I type "right" once or 10 or 1000 times. The output is dependent on my answer, not on the number of times I type that answer. I hope you understand.
To check if a condition is true inside a condition. For example If 5 == 5: If 6 == 7: Print("Hello") First it will check if 5 is equal five which is true then it checks if 6 is equal to 7 which is false so it won't print "hello" it goes from up to down. Hope that helps 😊.
the nested if prints the quotient of x and y. however, you can't do this if y=0 as you will get a zero division error (if x=0 and y=0, 0/0 can't be evaluated)
18:27 So the machine does the job of looking for something, for example, the free food on this video, it's like a human or a baby trying to find a way to reach it.
X = float(input("Choose a value for x: ") Y = float(input("choose a value for y: ") if (X==Y): print("X and Y are equal") if y != 0 print("therefore X / Y is: ", x/y) elif (X
Both X and Y need closing parenthesis for float casting also needs a colon after if y != 0 and make sure your variables are uppercase as that is what you named them.
Whenever she shows the python codes on her PC's spyder, how she change from comment to code(vice versa) so quickly by dragging? is there any short cut for that functionality?
Hi people, anybody could give me a hand ? I'm trying to do the fingers exercises in the textbook for this course, and in chapter 3 there is one that says: 'Write a program that takes an integer enter by the user and prints two integers, root and pwr, such that 0 < pwr < 6 and root**pwr equals the integer entered by the user. If no such pair of integers exists, print a message saying so.' I'm really strugglin with the logic there and would gladly accept some help. Thank you
for range function, the parameters include start, end and steps. steps has default value of 1, therefore without explicitly specifying for the range function, you would get an iterator that output a sequence of values from 5,6,7,8,9,10 if it was range(5,11). However, since step was specified to be 2, each time the iterator will yield and output a new value equal to previous value + 2, which range(5, 11, 2) give you 5, 7, 9. Also since 11 will be greater and equal to 11, so 11 won't be part of the result for the range function.
To whoever made the subtitles for this 40+ minutes video. Thank you.
X2
X3.
X4
X5
I think its the speech synthesizer
pre labeling
0:02:08 Strings
0:03:48 (Coding)
0:06:31 Input/Output:print
0:08:21 (Coding)
0:09:57 Input/Output:(" ")
0:12:14 (Coding)
0:14:00 Comparison operators on int , float , string
0:17:06 MIT map
0:18:00
0:19:58 Control flow - branching
0:20:00 0:22:00
0:24:51 Indentation
0:25:46 =vs== 0:28:00
0:28:58 Control flow : while loops
0:31:57 Control flow : while and for loops
0:35:09 Control flow : loops
0:36:44 range (start , stop , step) 0:38:00
0:39:42 (Coding)
0:41:06 break Statement
0:42:26 for vs while loops
You the real MVP
thanks for timestamping every video
Thank you, representative.
Love MIT for their CS OCW!!! One comment to add here. When you ask Python to compare two strings (like mentioned in the video "a" > "b" and the result is False) in the backend, Python is comparing their ASCII values (ASCII value of "a" = 97 and ASCII value of "b" = 98. Hence False)
thanks
I dont know if this is entirely true, if i do "ab" == "ba". the result is false. (She said something about lexicographical)
@@r4ko276String equality checks if two strings have the same contents. Checking if a string is greater than another string (string inequality) checks if the first string comes after the second string if you were to sort them alphabetically.
Kind of wish I got to experience CS at MIT. I loved my professors but this is a professor I know I'd like and learn alot from. Plus MIT's reputation is unmatched.
Same, except for me it would've been math/statistics. MIT was the only school I couldn't get accepted into (it was my dream school as a high school student). Having access to this open courseware in my 30s gives me a chance to check some of it out (just in a different subject).
I am very lucky and happy to see the smiley ,energetic and enthusiastic face of ANA mam ,when she tried to listen the question that the student asks.BUT AT OTHER PLACES , THIS HAPPENS RARELY BUT NOT IN MIT.
Me and a fellow colleague are leaping into Python (my native language being R). The lecture videos are well-paced and the lecturing style is top notch! I lecture the occasional statistical programming course, and it's not always easy to keep it interesting and engaging like it is here.
You're a good teacher, accessible yet giving your students a chance to learn.
For those curious about how Dr. Bell commented out certain lines of code here's the shortcut list,
Single line comment
Ctrl + 1
Multi-line comment select the lines to be commented
Ctrl + 4
Unblock Multi-line comment
Ctrl + 5
P.S: Got this from Stack Overflow so due credit to the actual authors for this query.
Dr.Bell, can't thank you enough for the great explanation.
THANK YOU, MIT COURSEWARE and sponsors! ❤️
Had somebody taught flow control statements as clearly as Dr.Bell my coding journey would have been at stratospheric levels...these lecture ignited my hopes of becoming a good programmer...
Really good for a start with Python. Great work Dr. Bell (and Professor Grimson).
Dr. Ana Bell is great teacher.❤❤❤ You are very good at explaining and in all perspective. You are best.Thanks MIT for Dr. Ana Bell.
Thanks MIT for OCW.MIT is best and doing great work.
Really liked the Zelda example, loved the flipping table :) Well played, Dr. Bell!
What a smooth lecture ! Thank you ! You helped me understand Python. My professor did a terrible job teaching this. Thanks MIT !
She is so adorable, I really love her lessons. Thanks MIT.
the best lecture on python, the reason why mit is a top college in the world
Wonderful lectures by Prof. Ana Bell. Thank you MIT OCW.
you're brilliant Dr. Bell. love your lectures💜
The idea behind ocw is profound. By distributing knowledge to the whole world for free, MIT is paying tribute to the geniuses like faraday, curie, ramanujan etc... Who produced phenomenal works despite of not having the proper access to the knowledge they needed.
38:54
both codes ARE WORNG
SHOULD BE
for i in range(5, 11, 2 ):
print(i)
NOT LIKE :
x = 0
for i in range(5, 11, 2 ):
x += i
print(x)
I get output : 21 with that code for some reasons
This is the best MIT has to offer.
Good thing its free.
Superb video of excellent teaching. I wish she was my professor when I was an undergrad.
Dr Bell
Your class was comfortable and interesting. Thank you for not writing on the board.
if course_grade == A:
print("this teacher is amazing")
elif course_grade in range (A, C+):
print("This teacher is really good!")
else:
if course_grade
Else :
If course_grade
Syntax error
For else: you shouldn't give a
OMG, these are finally in HD!
Thank you open courseware for providing such high quality leacture and materials..hope you have a great day😊
I love your problem sets. They really made me want to hit my head with a piece of wood over and over again. Real learning guys.
Jordy Muñoz Aravena
The ones found on the website? The ones that make you have to look up everything yourself before you can even do them?
Hey! Could you please share the link of the problem sets? Thank You!
@Виктор Мещеряков THANK YOU SO VERY MUCH!
Excellent lecture. Makes me wish I were back as a student. this is the best explanation of for & while loops I have seen. I wish I could take this course, but I no longer live in Boston.
I really love this lectures and completed my some basic python syntax and basic algorithm related concepts thanks for this contribution.
thank you Dr Ana Bell this was a really helpful and fun course !
you can actually use a for-loop to get input in Python - create a simple iterator class where __next__ returns a value from a call to input().
Regarding range(stop,start,step) 40:30: Normally num-1, but in this case, we're going to the end minus "two". (num - 2). I came across a component of this topic on stackoverflow, where someone described the end of the range as "minus two", which left me puzzled, so I thought I'd post.
Python always has the extra +1 whenever there is a range. This is different if you come from other programming languages but once you get used to it it will not bother you. Also true when slicing a string.
For example:
# 1 1 1
# 0 1 2 3 4 5 6 7 8 9 0 1 2
a = "hello, world!" # h e l l o , w o r l d !
b= a[1:8]
print(b)
# output
# ello, w
@@mvisperas In the case of range(5,11,2) From five up to but not including 11. It went 5...7...9 It stops at 9, and She says "...So we're going to the end MINUS ONE...." But actually it's going to the end, MINUS TWO. But I still agree with your comment. Normally, if it were range (5,11), with one hop as the default, it would be getting to the end (11) minus one. It was just a small thing, but thought I'd mention it. Yes, I see how you're thinking.
Another example: Two hops. It goes to the end "minus two".
for num in range(6,26,2):
print(num, "", end="")
6 8 10 12 14 16 18 20 22 24
I also tried to index a range, but you have to change it to a list first because range is immutable. Range 20 up to, but not including, 50. Two hops. So up to the end "minus two".
range_2 = list(range(20,50))
print(range_2[0:30:2],"", end="" )
[20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48]
@@algemmegla9002 The end value is always the highest value without being equal to or exceeding the stop value - you can treat it as always less than. This statement is true whether the step value is 1, or 2, or 3, or whatever step value you choose. Thus if you do range(5, 11, 3) then the count is 5 ... 8. It won't do 11 as it is equal to the stop value.
@@mvisperas I understand. Whatever is equal to the stop value gets ignored. I think we're both saying the same thing, but we're just wording our examples differently. As you mentioned in your example, you could say it stops at 11 because it is equal to the stop value, "and" you could also say it goes up to the end "minus two" (or 8) We're both saying the same thing. It's just different ways of explaining the concept.
OBLI WATCHED THIS FROM SRI LANKA.TO BE HONEST NONE OF UNIVERSITIES OF SRI LANKA PROVIDE GOOD LECTURES LIKE THESE
her legend of zelda example was a really excellent example to use and keep students engaged
VERY VERY thanks ,MIT open coursewarde.
She is second(I'm confused) best professor i ever got on MIT
Adorable teacher. Excellent lecture.
9:40 get input from user...every thing id a string, evento the numbers
This woman is so adorably awkward, nervous and brilliant.
not really awkward but i think this is her first lecture on this topic
thank you Dr Bell ! , rock on! better explained than my school lessons 4sure
take = "Thank you"
name = "Dr. Ana Bell"
print (take + ", " + name)
(take, name)*
print(take,","name,"!") is probably slightly better. ;-)
@@geitekop507 (take, " ", name, "!")
print(take+",",name)
I love this teacher!! She's so funny, but in the driest way possible!! It's great! 😅
Transition from if-else to while loop tells how much i took the loops for granted .
Who knew Darlene would be such a good professor
I want to ask a question not related to syllabus but a great tips Dr. Ana Bell used in this lecture, Lecture No 2(Branching and Iteration) and I have question in Time:39.48/43.30.... Here Dr. Ana used a great tips: She just select some sort of lines and deleted the "#" sign in a single moment.... I want to know how can I do it the same thing on Spyder.... Please comment to me... If you know please give me suggestion... Please Please.... (From INDIA)
SHE IS SUCH A GOOD TEACHER
I want to learn a lessong everyday if she is my teacher. I will never get tired or bored
Dr Bell, you are the best❤❤
to improve examples e.g. for string print( "you_can", "show", "where_the_spaces_are_added", "!" * 3 )
the example code blocks could have a colored background or have a colored border
Присоединяюсь. к отзыву "walawave
", за субтитры. Thank you very much
32:21.... y no n += 1?? also loving the Corse so far, did problem sets 0 and 1a before watching this, would love to go to MIT at some point in my life to get a Comp sci degree
Bro where can I get the problem sets and where can I install the notes prof Ana made that she shows here?
best python tutorial ever
It would help that when Ana points to the board and makes a comment, the camera also shows the board and not the picture of Ana talking.
thanks for the free lectures
00:19:58 if/elif/else
I am not getting that one at 12:26
I am doing this in Google colab,
Is that the problem
great course but can anyone tell me how she removed and added just the hashtags at 5:03??
@@secondary2415 do you know which shortcut she used?
@@secondary2415 oh I found it, it's okay, thanks
As a mechanical engineer who is interested also in CS. These MIT courses are great way to learn
Could someone please explain what's the difference between the "+=" and "=+" operators?
there is no such a sintax in python as "=+", only "+=". And "x += 1" is the same thing as "x = x + 1"
19:40 three ways to make decitions
"b" is greater than "a" because __lt__ / __gt__ methods of the string class were made to convert the characters to ascii values and return the comparison of those values?
Thanking MIT OCW Please upload more 💙
mam, i really loved the way you teach.
28:10 While loop insted of if statement
5:00 the estar operator with strings
9:55 to get input from user
Ana Bell ❤❤
Anaconda allows intereacitivty: IPython + Spyder (inspire on Matlab, (Matplotlib),+ support for other languages like ruby, R, Julia, Haskell ....etc. wow I am going to explore that tomorrow...
I can't get enough my brain is finally feeling euphoric
13:14 true por false. Comparing things
*My takeaways:*
*for loop* vs *while loop* 42:13
Sreedevi Sivakumar ahh, where did you see me?
Sreedevi Sivakumar good choices. If you want to learn deep learning, check out DeepMind 2020 lectures.
how do you remove the # from multiple lines in spyder? whats the hotkey.
theres probably also a hotkey to a add it.
so comment/ uncomment selected lines. like at 39:48
highlight the text and press ctrl+1
@@rizwanzeb5218 Thank you very much... so happy to get my solution
For the
while main_condition:
while sub_condition:
expression_a()
break # This break always happens
expression_b() # This will never execute
expression_c()
What is the point of having expression b if it will never execute?
Can someone tell me how she deleted and adds character to each line at once. Can it be done on windows?
I asked same question.... Even I don't know how she can able to do it... By looking at her screen view I think she uses Windows Machine... Please brother if you get your answer please reply to me also....
If you're using an IDE like Spyder, here's the shortcut key to it,
Single line comment
Ctrl + 1
Multi-line comment select the lines to be commented
Ctrl + 4
Unblock Multi-line comment
Ctrl + 5
P.S: Got this from Stack Overflow so due credit to the actual authors for this query.
@@diggitycat6233 A lot of thanks to you sir😄
for the maze game, " n=input("you are in a deep forest.
****************
****************
Go left or right?")"under the while loop doesn't need any print command and it just repeats itself?
Why isn't "Type a number..." included in the output, as it is included within the quotation marks?
So do we need spyder? because I'm using 3.6 and some of this doesn't seem to translate.
Dr Bell is a legend
The 'if' nested in an 'if' would only be considered if the parent 'if' is true, the 'else' nested in that won't ever be considered, then why use it at all?
Also if all the nested 'if's have same condition during nesting then if they are true, it'll execute them all at once, so what is the use of that?
What we want is that it asks us the question and show us the forest screen until we enter a 'left', so what we want it to do is to repeat this 'if' condition again and again so that it asks us that question again and again
X=input (" left/right..?")
If x== "right":
Else:
How can we do that?
I didn't understand the need for while here, because for it to ask us the same question again an again we will have to run this code again and again, and that can be done with an 'if-else' condition as well.
We used a while loop because we don't know how many times the user will enter right.
x = input (" left/right..?")
If x== "right":
Else:
will take the input only once. What if I want to go right twice?
Let's say, you use 7 nested if statements, the program would ask the user for direction 7 times. Not more, not less. What if I want to go right 10 times? I wouldn't be able to.
Notice the condition of her while loop. It doesn't matter whether I type "right" once or 10 or 1000 times. The output is dependent on my answer, not on the number of times I type that answer.
I hope you understand.
@@AbhishekGupta0710 yea, but that while command won't ask for input after I've entered it once, would it?
24:50 indentation
nice lectures delivery....dr bell
at 25:16
what's the use of the nested if?
and when will it be used!
To check if a condition is true inside a condition. For example
If 5 == 5:
If 6 == 7:
Print("Hello")
First it will check if 5 is equal five which is true then it checks if 6 is equal to 7 which is false so it won't print "hello" it goes from up to down. Hope that helps 😊.
the nested if prints the quotient of x and y. however, you can't do this if y=0 as you will get a zero division error (if x=0 and y=0, 0/0 can't be evaluated)
How can i delete # on each line for one time?
just select all lines and ctrl+1
did any one made expanding for the code of the game that puts sad face and many tables after entering right more than two times?
𝚗 = 𝚒𝚗𝚙𝚞𝚝("𝚈𝚘𝚞 𝚊𝚛𝚎 𝚒𝚗 𝚝𝚑𝚎 𝙻𝚘𝚜𝚝 𝙵𝚘𝚛𝚎𝚜𝚝, 𝙶𝚘 𝚕𝚎𝚏𝚝 𝚘𝚛 𝚛𝚒𝚐𝚑𝚝?")
𝚠𝚑𝚒𝚕𝚎 𝚗 == "𝚛𝚒𝚐𝚑𝚝" 𝚘𝚛 𝚗 == "𝚁𝚒𝚐𝚑𝚝":
𝚛𝚒𝚐𝚑𝚝𝚜 = 𝟶
𝚏𝚘𝚛 𝚒 𝚒𝚗 𝚛𝚊𝚗𝚐𝚎 (𝟷):
𝚛𝚒𝚐𝚑𝚝𝚜 += 𝚒
𝚗 = 𝚒𝚗𝚙𝚞𝚝("𝚜𝚊𝚍𝚏𝚊𝚌𝚎, 𝚕𝚎𝚏𝚝 𝚘𝚛 𝚛𝚒𝚐𝚑𝚝?")
𝚗 = 𝚒𝚗𝚙𝚞𝚝('𝚏𝚕𝚒𝚙𝚜 𝚝𝚊𝚋𝚕𝚎𝚜, 𝚕𝚎𝚏𝚝 𝚘𝚛 𝚛𝚒𝚐𝚑𝚝?')
𝚠𝚑𝚒𝚕𝚎 𝚗 == "𝚛𝚒𝚐𝚑𝚝" 𝚘𝚛 𝚗 == "𝚁𝚒𝚐𝚑𝚝":
𝚗 = 𝚒𝚗𝚙𝚞𝚝('𝚏𝚕𝚒𝚙𝚜 𝚝𝚊𝚋𝚕𝚎𝚜, 𝚕𝚎𝚏𝚝 𝚘𝚛 𝚛𝚒𝚐𝚑𝚝?')
𝚙𝚛𝚒𝚗𝚝("\𝚗𝚈𝚘𝚞 𝚐𝚘𝚝 𝚘𝚞𝚝 𝚘𝚏 𝚝𝚑𝚎 𝙻𝚘𝚜𝚝 𝙵𝚘𝚛𝚎𝚜𝚝!\𝚗\𝚘/")
the number you mention in parenthesis in for loop doesn't printed on the screen
AMAZING LECTURE
Thanks a lot Dr. Anna Bell
2:00 Strings
13:50 Comparison
how did she comment on multiple lines at once ?? By the way great lecture!!!
Ctrl + 4
18:27 So the machine does the job of looking for something, for example, the free food on this video, it's like a human or a baby trying to find a way to reach it.
i have a question, how do you remove the first hashtags in a column with a shortcut?
X = float(input("Choose a value for x: ")
Y = float(input("choose a value for y: ")
if (X==Y):
print("X and Y are equal")
if y != 0
print("therefore X / Y is: ", x/y)
elif (X
You have not closed the first Parenthesis of float casting.
Both X and Y need closing parenthesis for float casting also needs a colon after if y != 0 and make sure your variables are uppercase as that is what you named them.
19:45 if statement
Whenever she shows the python codes on her PC's spyder, how she change from comment to code(vice versa) so quickly by dragging? is there any short cut for that functionality?
If you press ctrl+1 in Spyder, all marked code changes to/from comment
@@Viruz256 Thank you! I was looking for this comment/answer!
1:50 strings objects
12:28 Ufff that excitement...😍
Hi people, anybody could give me a hand ?
I'm trying to do the fingers exercises in the textbook for this course, and in chapter 3 there is one that says:
'Write a program that takes an integer enter by the user and prints two integers, root and pwr, such that 0 < pwr < 6 and root**pwr equals the integer entered by the user. If no such pair of integers exists, print a message saying so.'
I'm really strugglin with the logic there and would gladly accept some help. Thank you
3:05 concatenation
on the 40th minute why i has the values 5 7 9 not 5 6 7 8 9 ?????
please explain !!!
for range function, the parameters include start, end and steps. steps has default value of 1, therefore without explicitly specifying for the range function, you would get an iterator that output a sequence of values from 5,6,7,8,9,10 if it was range(5,11). However, since step was specified to be 2, each time the iterator will yield and output a new value equal to previous value + 2, which range(5, 11, 2) give you 5, 7, 9. Also since 11 will be greater and equal to 11, so 11 won't be part of the result for the range function.