Slicing in Python Example | Python Tutorial for Beginners in Hindi

  Рет қаралды 986

Code-yug

Code-yug

Күн бұрын

Пікірлер: 19
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
Learning something new is always special..Thanks
@rrrrrrr000rrr
@rrrrrrr000rrr 9 ай бұрын
Kya aap python web development ke project pe video bana sakate hai?? Ek 3 tier application honi chahiye, jisme front end html, css, javascript me ho.. dijango/flask koi bhi framework ho and backend python me hona chahiye.. please
@bidhanry9740
@bidhanry9740 9 ай бұрын
THANKS FOR ANSWERING MY QUESTION
@Codeyug
@Codeyug 9 ай бұрын
Hope your doubt is cleared..
@bidhanry9740
@bidhanry9740 9 ай бұрын
@@Codeyug yes
@Adi_motion1016
@Adi_motion1016 9 ай бұрын
Please suggest me roadmap for python advance.
@User-tq3fz
@User-tq3fz 8 ай бұрын
Sir , I have a doubt What is the default stop value for negative step value?
@sonamporwal925
@sonamporwal925 9 ай бұрын
Input : 'sp#@ert*%q' Output: 'qt#@rep*%s' How to solve this question where alphabets will reverse but symbol remain on same place
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
import string alphabet = list(string.ascii_lowercase) #[a,b,c.....z] mystring = 'sp#@ert*%q' string_list = list(mystring) #['s', 'p', '#', '@', 'e', 'r', 't', '*', '%', 'q'] left = 0 right = len(string_list)-1 while left < right: if string_list[left] in alphabet and string_list[right] in alphabet: string_list[left],string_list[right] = string_list[right],string_list[left] right -= 1 left += 1 elif string_list[left] in alphabet and string_list[right] not in alphabet: right -= 1 elif string_list[left] not in alphabet and string_list[right] in alphabet: left += 1 else: right -= 1 left += 1 print(''.join(string_list)) Hope this helps!
@sonamporwal925
@sonamporwal925 9 ай бұрын
@@Shantanu_lrnr Thankyou for providing the solution ! It's working 👍
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
@@sonamporwal925 👍👍
@rrrrrrr000rrr
@rrrrrrr000rrr 9 ай бұрын
list = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'] def text_manipulate(text, manipulate_amount, direction): new_text = "" if direction == "decrypt": manipulate_amount = manipulate_amount * (-1) for letter in text: if letter in list: old_position = list.index(letter) new_position = old_position + manipulate_amount new_text = new_text + list[new_position] else: new_text = new_text + letter return print(f"The {direction}d result: {new_text}") direction = input("Type 'encrypt' to encrypt, type 'decrypt' to decrypt: ") text = input("Type your message: ").lower() manipulate_amount = int(input("Type the shift number: ")) manipulate_amount = manipulate_amount % 26 text_manipulate(text, manipulate_amount, direction)
@aarizmansuri-g8p
@aarizmansuri-g8p 9 ай бұрын
how are you sir , iska reverse karna hai lekin 1step chor ke 1step ( how era you ris ) interviw me puchata muje , iska easy se easy way batayiye sir
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
mystring = 'how are you sir' string_list = mystring.split() mylist = [word if word == string_list[0] else word[::-1] for word in string_list] print(' '.join(mylist)) Hope this helps!
@aarizmansuri-g8p
@aarizmansuri-g8p 9 ай бұрын
@@Shantanu_lrnr thank you
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
@@aarizmansuri-g8p 👍👍
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
​@@aarizmansuri-g8p👍👍
@Shantanu_lrnr
@Shantanu_lrnr 9 ай бұрын
@@aarizmansuri-g8p 👍👍
Lamborghini vs Smoke 😱
00:38
Topper Guild
Рет қаралды 67 МЛН
Мен атып көрмегенмін ! | Qalam | 5 серия
25:41
Python OOP Tutorial 1: Classes and Instances
15:24
Corey Schafer
Рет қаралды 4,5 МЛН
Nested List in Python | Python Tutorials for Beginners #lec37
11:06
Jenny's Lectures CS IT
Рет қаралды 92 М.
Python Threading Explained in 8 Minutes
8:39
NeuralNine
Рет қаралды 160 М.
#20 Python Tutorial for Beginners | While Loop in Python
12:43
Telusko
Рет қаралды 1,6 МЛН
Create a QUIZ GAME with Python 💯
9:29
Bro Code
Рет қаралды 229 М.