Nice vdo..we can do comprehension of tuple by using its type print(tuple(i*2 for i in range(2)) ) # Tuple (0, 2) print({i:i*2 for i in range(2)} ) # dict {0: 0, 1: 2} l = [2,4,6] print ([i*2 for i in l if i > 1] )# List [4, 8, 12] print({i*2 for i in l if i > 1 }) # set {8, 4, 12}
At 6:53 you didn't provide parenthesis for tuple, then how can you define that tuple can be unpacked. I understand that the output will be the same but I am just trying to indicate your mistake.
We can unpack list also.
I was just going to scold u black and blue for that🤣
a,b,c,d=[21,32,93,'hello',5]
print(c)
a,b,c,d='ABC',21,32,93,'hello',5
print(c)
I am facing the same issue for both
@@Dabber7 thats what happens.. we can unpack list too... not everyone who teaches in youTube is correct all the time...
yes its correct
it is possible to unpack list also.
list and tuple both we can do packing and unpacking
What is meant by pack/unpack ? 😅😅
i dont usually comment on youtube but man what a great teaching every line with example...subscibing you
Thanks and please do share..
Nice vdo..we can do comprehension of tuple by using its type
print(tuple(i*2 for i in range(2)) ) # Tuple (0, 2)
print({i:i*2 for i in range(2)} ) # dict {0: 0, 1: 2}
l = [2,4,6]
print ([i*2 for i in l if i > 1] )# List [4, 8, 12]
print({i*2 for i in l if i > 1 }) # set {8, 4, 12}
But, actually it is generator and not comprehension.. Please check type here...
Very nice thankyou so much it was realy different from others video
Thank you.. Please share with friends..
out of the world explanation
Keep learning
Kaash aapkee jaisa sir hamare college m hota🥹🙂
well explanation sir....
we can unpack list and tuples . when i tried for output both came without error. i was wondering what am i wrong or my computer is
Your explanation is amazing
Thanks and check playlists please
Thank you so much darling 💓
हर हर महादेव जय माँ भवानी जय श्रीराम जय माँ सीता जय हनुमानजी 🙏🙏🙏🙏🙏❤❤❤❤❤❤❤❤🚩🚩🚩🚩🚩🚩🚩🚩🚩🚩
nyc but we can unpack list also.. try it guys as same as tuple
Your teaching techniques is too good
Thanks a lot
Aaj Mera name esme example liya 😅😊😢😊
Best video 🙌
Thank you and keep going..
L = ['hello' , 23 , 30 , 'ram']
a,b,c,d = L
print (b)
unpacking ho rhi h
Yess... Please check my comment below the video
Superb video. Very informative.
Thanks... Keep going
❤ Thank you Bhai
Please check playlist section of this channel
Good explanation. Thanks.
Keep going.. 👍
Very clear explanation Sir👍
Thanks
Nace presentation brother appreciate
Keep watching and keep learning
It is very good👍
Thank you and keep learning
Great 👍❤️
Keep going bro..
unpacking can be happen in list
7:36 is it the wrong you have said at this point, tupple can be modify, and list provide more security to data
Item ❌️ Atom ✅️
Thanks 👍😊
thank you sir
Check playlists..
At 6:53 you didn't provide parenthesis for tuple, then how can you define that tuple can be unpacked. I understand that the output will be the same but I am just trying to indicate your mistake.
var1, var2, var3 = 10,20,30 is unpacking of tuple. I don't think there is a mistake.
We can unpack list like tuple I am able to do it .
Nice
I was thinking packing n unpacking is able in list
Now, it's cleared... Right?
@@Codeyug yes and this ques was in my exam yesterday thanks ❤
i tried unpacking with list as you said and it works.... how it is possible
j, k, l, m, = [1, 5.4, 'abc', 2+3j]
print(j)
print(k)
print(l)
print(m)
Working is changed into new version. I have also commented in the same video and pinned it
Amazing🙏
Thank you so much.. Keep learning from my channel. There are number of playlists
Very nice
Thanks...you can learn python from this channel
Osm brother
Thanks 🤗
Why? Sir number 4 topic?
sir, which software are you using for code in this video
Vscode
aa,ba,ca,da=[1,5,3,4]
print(aa,ba,ca,da)
a,b,c,d=(1,2,4,5)
print(a,b,c,d)
both are giving same result in python 3.0 why
Sorry, we can unpack tuple.. I guess, I did mistake.
Modification kelye list chahea ya tuple?
List
Good expl
Thanks
Hi bro if vs for loops plz 🙏 explan
packin and unpacking is supporting list
But Maine list ke liye try kiya . Replit(online) pe .
Unpacking ho raha hai . Pls help
Unpack hota hai... It depends on version I guess.. Comments check kro.
One correction:
List also supports unpacking :)
😊❤❤❤
Hi bro oops in python explan 😊😊plz
Full playlist hai bro..
Thank you bro
Mila kya?
@@Codeyug yes bro mil gaya thank you bro
@@samrat.02 'oop using python codeyug' esse bhi mil jayega
Nice video bro
Thank you.. If Anything required, text me..
@@Codeyug sure bro
U were wrong coz Unpacking is possible with list
Last difference is wrong
Yess..sorry for that
Bro plzz muj se insta pr rbta kren ya whatsapp prr muje python K bary mein ap se jan kari leni ha
Please ask here
Thank you sir
Welcome
Nice
Thanks