sir mera parso board hai , pure saal dhang se nahi padha but aaj aapki videos dekh kr maza aagaya pura syllabus complete krlia and jo coding merko 10th se smjh ni aaya uski aaj clarity hogyi thank you :)))
in the question where we have to write a code to print last line of file : you can use this code also: f=open("1.txt","r") x=f.readlines() print(x[-1])
@@Insigneon might their advertisement team forgot.....they have an option to whom they will be showing this advertisement like to those on P.C or T.V or mobile phone
7:32 code is not valid gives error. Corrected code- file=open('data.txt','r') line=file.readlines() last=line[-1] print(last) 11:21 also gives error. Corrected code- def displayword(): a=open('Answer.txt','r') b=a.read() c=b.split() for i in range(len(c)): if len(c[i])>4: print(c[i]) else: continue Or you could just assign and empty variable first like a=' ' While a: Like that but for loop is more easy. Atleast for me.
I also tried the second code on 11:21, the program says local scope a can't be accessed. I think for a while and tried many changes in the code. Final conclusion is this Code:- def Displaywords(): f=open('Lyrics.txt', 'r') a=f.read() L=a.split() for j in L: if (len(j)
BHAIYA I KNOW YOU TRYING TO CREATE A BULK BUT PLEASE UPLOAD ALL OF PYTHON ASAP BECAUSE WE HAVE BOARDS,PRACTICALS ,AS WELL AS MAINS RIGHT INFRONT OF US , DON'T HAVE MUCH TIME LEFT HOPE U UNDERSTAND......
Ha sacchi Bhaiya load aaa jata hai python ka plzzzz Bhaiya upload all the video lecture aur Bhaiya plzzz ap chapter start karne se pehele chapter no. Likh diya kijiye plzz easily samaj aaaa jata hai. ...
Hai hi ni na 😑😂tbhi poocha... actually hmari mam alg alg pdf send krri h hr chptr k...and ab mujhe confusion hori h koi bolra h sumita arora koi Preeti arora koi ncert... smjh ni ara m kaunsi lu
In the last program, the interpreter would give an error: "local variable 'a' referenced before assignment" To avoid this, before while loop, at line number 3, you'll have add one more line of code as follows: a =' ' and you're all good. :)
there is an error at 2:34 becoz we r opening a file(a) in write mode and trying to use read function in 4th line due to which print(p) will give an error
You don’t have to put delimiter keyword because the default delimiter is comma itself. Also, you don’t need a loop of .writerow(), you can just pass the nested list in .writerows()
7:40 sir f=open(............,'r') R=f.readlines() x=R[-1] print(x) se bhi toh ajayega as readlines list me bana dega and -1 backward indexing se usko print kradenge am i right?
above the loop take a= " "(space or empty string) when u write while a: (you mean to say while there is a character the loop will keep going and when u reach the end, there is no characters so the while condition becomes false and loop terminates.
@apni kaksha Bhaiya aapne reading of a binary file me exception handling jaise use of try & except blocks bataye nahi hai Bhaiya pls include this also🙏
10:52 Sir you have done a lot of errors while writing this code. The correct code is given below: c=open('lyrics.txt', 'r') a=True while a: a=c.readline() b=a.split() for i in b: if len(i)
Sir please upload more videos i haven't completed my syllabus yet and i also don't know the syllabus exactly. I am only following you please make more videos 🙏
can you please make videos in english sir? You have many students from south india as well,trying to learn from your videos including me. and we find it really hard with hindi
Bhaiya please upload more videos I really need them in my school tomorrow is my cs exam and I depended on your videos but you didn't upload any lecture of cs for a long time due to which i haven't studied well .
Guys please say them to do Programming in python idle. It would be helpful in practicals also as we will know how to do programming. Please anyone say this to aman bhaiya😭.
the question 4 (9:51) I tried the code jo aapne bataaya tha but it showed error so mene khud se ek try kiya and its working completely fine.... def DISPLAYWORDS() : f= open("abc.txt",'r') a = f.read() l = a.split() for i in l: if len(i)
program at 7:37 doesn't work! it gives a runtime error as 'a is not defined', if you define initially a = f.readline(), after opening the file, it will still prints nothing This works for me: with open('test.txt', 'r') as f: a = f.readline() while a: b=a a = f.readline() print(b) And this also: with open('test.txt', 'r') as f: lastline = f.readlines()[-1] print(lastline)
For the 3rd question if you want to add file path you can use this code also: a=input("Enter 1st file name: ") b=input("Enter 2nd file name: ") x1='C:\\Users\\SANJU\\Desktop\\'+a+'.txt' x2='C:\\Users\\SANJU\\Desktop\\'+b+'.txt' f1=open(x1,'r') f2=open(x2,'w') l=f1.readlines() f2.writelines(l) f2.close()
to display words whose length less than 4 :
fp=open('blablabla'.txt','r')
words=fp.read().split()
for i in words:
if len(i)
3:33 nobita still getting zero 🤣🤣🤣
No one
Literally no one:
Harsh bhaiya - Parle-G ka achaar!!!
Who is wathching this right now for tomorrow's exam😅😂
✋✋Ez
Mehhh 😂
Wahh
Meee
1 night - whole syllabus
Thanku bhaiyaas and didis for changing the future of India.... guiding us towards a super power india (jbhi hoga)
Kaunsi book h python ki class 12 apki
@@nishimahara9126 sumita Arora
@@nikhillodhi7427 ok thanks
Sumita Arora h bhai..
sir mera parso board hai , pure saal dhang se nahi padha but aaj aapki videos dekh kr maza aagaya pura syllabus complete krlia and jo coding merko 10th se smjh ni aaya uski aaj clarity hogyi thank you :)))
Haan bhai Mera bhi hain exam
samjh aaya?
@@debapriyahazra
@@tripuytshorts3392 haan
in the question where we have to write a code to print last line of file :
you can use this code also:
f=open("1.txt","r")
x=f.readlines()
print(x[-1])
genius
@@techboyvikrant9048 Bhai yaad dila dia tune ki mene kabhi comment Kia tha , tab me 12th me tha , Aaj me IIT Kharagpur me hu btech in cse
@@xperthighlight topper
@@akarsh_24 😂😂nahi bhai me nahi hu iit me
This brave showing his ads like: wow! You really let this add in?😂🤦🏻.... Bro u won't be able to advertise if it wasn't for this ad 🤣
Plus who the heck watches yt via a browser on a smartphone.
Like wtf do you want us to do mate...
@@Insigneon they want us to use there browser
@@OmTheGreat based bro
But I like brave for not showing ads 😂
@@Insigneon might their advertisement team forgot.....they have an option to whom they will be showing this advertisement like to those on P.C or T.V or mobile phone
7:37 my method
a=open('data.txt','r')
b=a.readlines()
print(b[-1])
a.close()
thx bro i tried thi one prac but was giving error but by your method i got solution thank you very much
yaa same bhaiya
7:32 code is not valid gives error.
Corrected code-
file=open('data.txt','r')
line=file.readlines()
last=line[-1]
print(last)
11:21 also gives error.
Corrected code-
def displayword():
a=open('Answer.txt','r')
b=a.read()
c=b.split()
for i in range(len(c)):
if len(c[i])>4:
print(c[i])
else:
continue
Or you could just assign and empty variable first like
a=' '
While a:
Like that but for loop is more easy. Atleast for me.
Very nice bro.
I also tried the second code on 11:21, the program says local scope a can't be accessed.
I think for a while and tried many changes in the code.
Final conclusion is this Code:-
def Displaywords():
f=open('Lyrics.txt', 'r')
a=f.read()
L=a.split()
for j in L:
if (len(j)
@Nirmit Kun Nice
@@itachi03537 eren yeager
Aman bhaiya,, please bata do na ki aap Physics ki remaining chapter ki notes kab denge 📚📚please please reply🙏🙏 agar kisi ko pata hai please reply 🙏🙏🙏
Hmm bhaiya
Guys jyda se jyda like kro.. taaki Aman bhaiya dekhe
Preboard Shuru ho gaye please physics notes
Plz upload remaining physics notes bhaiya
Yes bhaiya please tell
to print last line:
fp=open('blablabla.txt','r')
lines=fp.read().splitlines()
lastline=lines[-1]
print(lastline)
or
f=open("yes.txt",r)
a=f.readlines()
print(a[-1])
BHAIYA I KNOW YOU TRYING TO CREATE A BULK BUT PLEASE UPLOAD ALL OF PYTHON ASAP BECAUSE WE HAVE BOARDS,PRACTICALS ,AS WELL AS MAINS RIGHT INFRONT OF US , DON'T HAVE MUCH TIME LEFT HOPE U UNDERSTAND......
Ha sacchi Bhaiya load aaa jata hai python ka plzzzz Bhaiya upload all the video lecture aur Bhaiya plzzz ap chapter start karne se pehele chapter no. Likh diya kijiye plzz easily samaj aaaa jata hai. ...
Kaunsi book h Python ki apke school m
@@nishimahara9126 sumita arora...... Hai hamare school ke.... Apki koonsi hai?
Hai hi ni na 😑😂tbhi poocha... actually hmari mam alg alg pdf send krri h hr chptr k...and ab mujhe confusion hori h koi bolra h sumita arora koi Preeti arora koi ncert... smjh ni ara m kaunsi lu
@@nishimahara9126 oooo.....nhi hamara sumita hai.....by the way kaunsi school hai apki????
In the last program, the interpreter would give an error: "local variable 'a' referenced before assignment"
To avoid this, before while loop, at line number 3, you'll have add one more line of code as follows:
a =' '
and you're all good. :)
are you mayank kumar? st. marks school?
Yes you are right as I have tried the program and it is giving error.
3:51 Nobita supremacy!! love the way you teach sir
3:20 - CSV FILES
4:00 - Reading a CSV FILE
4:45 - writing a csv file
5:45 - Practice time
9:50 -Q3 imp
there is an error at 2:34 becoz we r opening a file(a) in write mode and trying to use read function in 4th line
due to which print(p) will give an error
Can you please tell me how to rectify the error
sir please upload the next lecture because my preboard will be start
15 January
Who is watching this right now for tomorrow's exam 😂😂
😁
Meeeee
Not me dah
Ha na
Yesn't
You don’t have to put delimiter keyword because the default delimiter is comma itself. Also, you don’t need a loop of .writerow(), you can just pass the nested list in .writerows()
Okay
3:54 WHO ELSE NOTICED NOBITA=0 MARKS 😂😂😂
Tumhara billa billa mera billa doreamon 😁😜
@@darshanxarijit 🤣🤣🤣
Thank you bhaiya .... It's helping a lot.
Physics ke notes updload kardo pls optics and modern
7:40 sir
f=open(............,'r')
R=f.readlines()
x=R[-1]
print(x)
se bhi toh ajayega as readlines list me bana dega and -1 backward indexing se
usko print kradenge
am i right?
In 7:12 you need to define variable 'a' beforehand else it will give NameError as a is not defined.
Correct
Sir please upload all lectures and completed MySQL ASAP.
We are having aur preboards in front of us🙏🙏🙏🙏
Thanks a lot harsh bhaiya ..😊😊
Thanks bhaiya you are the best😎
2:24 you can't read from 'w' mode, right? then how is it "p=a.read()"
At 3:56 marks of Nobita😁😁
How realistic bhaiya😅
I like the fact that a fictional character seems *realistic*
Bro I'm watching this right now for tomorrow board final exam
looks like we are on same boat
awesomeness has no ending😄😄😄
bhaiya 7:33 pe error ayega because before going in while loop, 'a' must be defined which u defined inside the loop.
you are right
above the loop take a= " "(space or empty string)
when u write while a: (you mean to say while there is a character the loop will keep going and when u reach the end, there is no characters so the while condition becomes false and loop terminates.
Last line print nhi ho rahi hai
With a slow speed of speaking this lecture can be better than school lectures
Thank you so much Bhaiyaa... Pls aage k Lec bhi daal do python k pls... Pls... Bhaiyaa 😵😥
Sir please upload next lecture 💙💙💙💙
thanks, bhaiyya...
Ab please marathon me syllabus revision complete kara do! 🙏🏼🙏🏼
Boards in may
This guy really loves Parle-G and Tindey. 😆🤣
3:34 sir really knows which cartoon character has best and worst academic background 😂😂😂
Mistake at 2:16 when the file1.txt opens in write mode then how we are reading the file
??
4 ghante me exam hai, moye moye
Bhai 1 ghante me hai
3:19 he literally gave Nobita "0" marks 😂😂
7:24, f.readlines karke print(L[-1]) chalega?
chatgpt 🤡
@@surferr jab sare queries programs chatgpt se le sakte h fir ham padh kyu re h .............bc education system hii kharab h
@@Jatin.pandattt education system nhi, it's just ai, isliye log ml krre h zyada
Bhaiyaa, kya aap sab chapter ke definitions bhi notes me include kar sakthe hai? Thank you for ur effort ❤️
Kaunsi book h tunhare school m python ki?
@apni kaksha
Bhaiya aapne reading of a binary file me exception handling jaise use of try & except blocks bataye nahi hai
Bhaiya pls include this also🙏
10:52 Sir you have done a lot of errors while writing this code. The correct code is given below:
c=open('lyrics.txt', 'r')
a=True
while a:
a=c.readline()
b=a.split()
for i in b:
if len(i)
Term 1board exam 4.06 am 7 hr to go....🙂 21 dec
Sir please upload more videos i haven't completed my syllabus yet and i also don't know the syllabus exactly. I am only following you please make more videos 🙏
Nitro Your Speed 🚅
We have to fight with Thanos who killed our Vision.⚡
the code of the first question will give an error because in the first iteration the value of a is not defined.
you caught it
Pls increase the frequency of lectures of cs
Pre boards has already started just complete the lectures soon please 🙏🙏
Awesome Sir :) 🔥🙏✌👏😇👍😎👌🤘
3:00 I think there is some typing mistake ,bcz when you open file only writing mode you can't read bcz it not make any sense ?
Bhaiya while a: me 'a' to defined hi nhi tha tab to error ho jaega na?
Btw thank you so much for all videos
When will class 12th physics volume 2 notes will be uploaded?
Thanks sir 👐
Really thankful to Aman Bhaiya.. Keep growing and stay motivated..!!
Sir, it's my humble request from you and your team of apni kaksha to premiere this at early morning tomorrow is my cs preboard exam.. 🙏🙏🙏🙏
can you please make videos in english sir? You have many students from south india as well,trying to learn from your videos including me.
and we find it really hard with hindi
Switch on the sub titles. I know it's tough for you guys. All the best.
@@devanshchaudhary4098 no subtitles brother
sir , in the last question, while running the code it shows the error,
"while a:
UnboundLocalError: local variable 'a' referenced before assignment"
Please upload SQL Lectures also
Aplog Notes kyo nhi upload karte ho😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭😭🙄🙄😭
Abe to copy me likhona
Kb tk dussre ke bll me chaloge😑😑😑
@@shamsaarize5349 Abe gandu notes agar mil jata toh...... video ko pause ⏸️ karke nhi likhna padta......
@@chandankrmahato2202 bro khud se banyaa hua notes sabse best hotee hee
@@chandankrmahato2202 OP
@@chandankrmahato2202 well done bhai
They did my boi Nobita dirty 3:20
10:15 wo din door nhi jab hamare bacche bhi python padhenge...aur "file ka name" hamare poorvaj *BINOD ka naam denge😂👍🏻
6:55 this code is more efficient
f=open("file.txt","r")
l=f.readlines()
print(l[-1])
hn bhai while a mai error hai last question ka bhi source code da diyo bhai hlp hojyagi meri
while a wala code galat hai. telling 'a' is not defined.
Thank you so much sir ♥
f=open("C:\\Users\\Lenovo\\Desktop\\source.txt")
a=f.readline()
while a:
print(a)
a=f.readline()
correct code for qusetion 2.
sir plsease conduct the mcqs session on python class 12 for term 1........ sir pls help sir
If u wud hv explained evrything in detail it wud hv been vry helpful u r just running in the entire video just for the sake of covering the topic
Bhaiya please upload more videos
I really need them in my school tomorrow is my cs exam and I depended on your videos but you didn't upload any lecture of cs for a long time due to which i haven't studied well .
Sir plz upload next chapter 🙏🙏
Aman Bhai please try finishing computer syllabus before our practicals...I haven't touched our school book I've only been following your videos...
Guys please say them to do Programming in python idle. It would be helpful in practicals also as we will know how to do programming. Please anyone say this to aman bhaiya😭.
Agla lecture kb aayga ..
watching this before
12 hours to go exams cs............ :)
Plz upload next chapters fast 🥺🥺🥺🥺🥺🥺
5:56
But now the suitable line is, Ek tha raja
Ek thi Rani, alg thi caste, khtm Kahani 🙄
the question 4 (9:51) I tried the code jo aapne bataaya tha but it showed error
so mene khud se ek try kiya and its working completely fine....
def DISPLAYWORDS() :
f= open("abc.txt",'r')
a = f.read()
l = a.split()
for i in l:
if len(i)
Sir Please upload the next videos 🙏🙏🙏
program at 7:37 doesn't work! it gives a runtime error as 'a is not defined', if you define initially a = f.readline(), after opening the file, it will still prints nothing
This works for me:
with open('test.txt', 'r') as f:
a = f.readline()
while a:
b=a
a = f.readline()
print(b)
And this also:
with open('test.txt', 'r') as f:
lastline = f.readlines()[-1]
print(lastline)
Can You Please Upload One more Video LECTURE ON PYTHON CONNECTIVITY WITH MySQL, AS IT IS ALSO IN OUR COURSE
No bro
Physics notes please 📖📖📖📖
Alternate answer for last ques is
def displaywords():
f=open('lyrics.txt','r')
p=f.readlines()
for i in p:
j=i.split()
for k in j:
if len(k)
Mai toh 4:40 pe dekh raha hu 😅
bhaiya aage ka jaldi upload kar dijiye please and thank you for all these videos
Aage ke videos bhaiya?????? 3 weeks ho gye aapko python ke video upload kare🥺
Pta nhi yrr kb ayegi aage ki videos🙄
Plz upload the further videos fast because tomorrow is my preboard😅
If you don't want to close file use:
with open(filepath,mode) as fileobject:
Statement(s)
Bhaiya pls upload remaining lectures too. 🙏🏻
The teaching is well & good.
But the volune is very low.. if you raise the volume it would be much better:)
For the 3rd question if you want to add file path you can use this code also:
a=input("Enter 1st file name: ")
b=input("Enter 2nd file name: ")
x1='C:\\Users\\SANJU\\Desktop\\'+a+'.txt'
x2='C:\\Users\\SANJU\\Desktop\\'+b+'.txt'
f1=open(x1,'r')
f2=open(x2,'w')
l=f1.readlines()
f2.writelines(l)
f2.close()
Upload more videos Aman bhai
You are our hope for Class-12th PYTHON
@Apni Kaksha
11:05 it will give error because a is not defined before while!
Eat well, sleep well, study well.
Kon kon subah dekh rha hai 😢😂
Mai
Bas center ke bahar khada hu
F=open('data.txt','r')
s1= F.readlines()
s2=s1[-1]
print(s2)
Bhai aaj exam hai😢
Same😂😂
Same bro
Ch ni horaa smj hini ar na ssb smjnRa kya kru 😢😢
@@simranverma289 chor de bhai jaa ke so jaa abb kuch nahi kar sakta😂
@@sharadmishra2186best option
Kids: aam ka aachar...
Men: neembu ka aachar..
Legend: tinde ka aachar...
Legend pro max: Parle-G ka aachar...
😂😂😂😂🙌🙌🙌
Bhaiya d block ke notes upload kar do plz..
Already h
@@RohitRoy-fl3cm kaha
where can I find the notes of this video? thanks for the video tho it was really helpful :)