Python Strip String Method

Python Strip String Method

Master Code Online

8 лет назад

53,830 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Famous Fighter23
Famous Fighter23 - 13.11.2023 10:01

Thank you. Hopefully I can remember this for my test tomorrow

Ответить
Comet Blaze
Comet Blaze - 28.10.2023 17:02

def check_loan_eligibility(annual_income, credit_history, outstanding_debt, co_signer = False):
if(annual_income < 30000 or credit_history == False):
return False
elif(annual_income - outstanding_debt < 25000):
if(not co_signer):
return False
return True

Ответить
V
V - 28.10.2023 16:50

Muda o X,Y,Z

def calculate_paint_needed(width,length,height):
# Lateral Area * 2 + Front and Back Areas
total_area = 2 * height * width + 2 * height * length

# Calculate the number of liters needed: 1 liter covers 7 square meters
liters_needed = total_area / 7

# Round to 1 decimal
rounded_liters = round(liters_needed, 1)

# Output string
result = f"{rounded_liters} liters of paint are needed"
return result

print(calculate_paint_needed(X,Y,Z))

Ответить
hooman tehrani
hooman tehrani - 05.08.2023 14:19

COOL

Ответить
Jay Richest
Jay Richest - 11.04.2023 17:32

Great and quick explaination! Thanks! Jus subbed.

Ответить
Romeo
Romeo - 04.04.2023 17:31

Genius

Ответить
DoYouHaveAName1
DoYouHaveAName1 - 22.08.2022 20:40

Thank you for all your strip method videos, very helpful

Ответить
Cruzan9
Cruzan9 - 22.06.2022 22:39

I didn't realize this video was from 2015 when I watched it from my phone earlier. I'm on my computer now trying to work on this and so I'm guessing a lot has changed. I cannot get this work on any code editor but it works fine on Python IDLE. If I use single quotes it doesn't work but when I have text before and after the word with spaces on the left and right it works just fine. To anyone watching this in 2022 and have a better grasp of this please share your thoughts. Thanks!

Ответить
Escape Felicity
Escape Felicity - 28.05.2022 08:31

Get rid of the background noise

Ответить
DataLove
DataLove - 22.04.2021 14:01

Thank you soo much for this wonderful explanation.. :)

Ответить
Xesius Prime
Xesius Prime - 13.04.2021 10:21

im still confused.... i get that it strips the things you put in but i still dont see how it specifically goes about doing that

Ответить
John Bartmann
John Bartmann - 07.04.2021 11:18

So when searching a string for characters to remove, it basically gives up searching left to right when it finds its first mismatch and then skips to the end of the string? Can you elaborate on its behaviour? THanks!

Ответить
Karan B20
Karan B20 - 07.12.2020 21:33

most clear

Ответить
Zima Blue
Zima Blue - 22.11.2020 00:12

thanks man !!!!!!!!!!!

Ответить
Arthur Ivex
Arthur Ivex - 09.10.2020 22:59

Love the "strip schtring method". LOL

Ответить
Derick Blacido
Derick Blacido - 16.09.2020 00:41

Your video sucks

Ответить
tamyez alisaleh
tamyez alisaleh - 22.08.2020 14:27

Thank you
بارك الله فيك

Ответить
r vlli
r vlli - 19.06.2020 01:39

1. What if you want to get rid of all instances of a character, such as spaces, even when in the center?
2. What if you didn't want to strip off the n on the right but still wanted the n off from the left?

Ответить
Nouran Ramadan Moustafa ٢٠١٩٠٠٧٨٠
Nouran Ramadan Moustafa ٢٠١٩٠٠٧٨٠ - 05.05.2020 20:20

you are amazing

Ответить
Vishesh Goel
Vishesh Goel - 13.04.2020 19:58

how can i delete all the characters in the second string from the first string?

Ответить
محمد
محمد - 07.01.2020 02:41

You helped my head from a bad headache thank you

Ответить
PgUp
PgUp - 25.11.2019 11:17

This is really helpful and clear for cases with parameter in it!

Ответить
Hyeongjun Seo
Hyeongjun Seo - 17.11.2019 11:50

right string stip buffering method

Ответить
xd
xd - 25.09.2019 04:20

i prefer it to be called a stripping method. Nevertheless, thank you! :)

Ответить
Abhishek Bhardwaj
Abhishek Bhardwaj - 17.06.2019 14:48

exact explaination that I want. Thanks

Ответить
Zein El Mokhtar
Zein El Mokhtar - 02.04.2019 23:09

You are the only one that who explain how it actucally works!, i don't understand why someone would intreduce function without explaining how it really works. thank you very much mister.

Ответить
Rahul R. Lata
Rahul R. Lata - 29.03.2019 08:36

say ss rather than shriptshring

Ответить
Petrockspiracy
Petrockspiracy - 13.08.2018 19:38

This method is a life saver

Ответить
Julian Petit
Julian Petit - 09.06.2018 16:51

shtripshtring

Ответить
Tramnack
Tramnack - 25.02.2018 21:40

You saved my day in 10 Seconds

Ответить
Ash Chaudhari
Ash Chaudhari - 31.12.2017 09:09

What the fuck.....its too boring

Ответить
Shemin John
Shemin John - 03.09.2017 08:47

thanks :)

Ответить
sneaky ninya
sneaky ninya - 28.06.2016 00:02

im using a code where it takes strings out of a .txt file, where do i put the strip command to remove the \n?

Ответить