Skip to content
Advertisement

Tag: numbers

Can I somehow pick a specific number from a list?

I’m new at programming and i need help with my “work”. I need to print specific number from a list. List = from 1 to 10 000 and i need to pick every single number that has “375” as a last three digits For example: 375, 1375, 2375 etc. My english isn’t the best so I hope you undestood me

place the symbol

to add certain symbol after every three got splited lines Something like that?? – Answer This code looks if there are three or more commas in the text. If it is, it splits the text into 4 parts, then concats the 3 first parts and adds an @ before the third comma and redo the same process with the remaining

How to deny letters and symbols in loops

I only want my code to accept numbers between 1 to 9. I tried try except, logical operators, isdigit, but I just can’t do it. Answer It look like you’re trying to print out the prompt based on the user input, and you want to make sure that it’s not higher the 9 and lower than 1. You need to

Python: Generate random letter then Keystroke said letter

(I am using Python under Mac OS) Hey Guys, i am looking for a way to random generate a letter (a-z) and then keystroke it. The way I usually do keystrokes is: cmd = “”” osascript -e ‘tell application ‘System Events’ to keystroke “insert_letter_here”‘ “”” os.system(cmd) This won’t accept random.letter since it would keystroke the exact spelling of random.letter. Does

Advertisement