How to avoid line breaks in function arguments when formatting code in python?
My work environment: vscode + flake8 + AutoFormat After save
flake8.args: --ignore=E501,F401,W292,E203,F403
.
Varied amount of input data first time question
This is my first ever question. I’m working on a zybooks lab (6.12.1) – I’m pretty excited that I’ve actually wrote the code and it mostly works – THe problem I am having is that the average I am calculating is printing out with a decimal. I struggle with formatting but if I could get a hint with how to format it so the number shows as 10 vs 10.0 I would be very grateful (I Could google the answer and I could use Stack to find it but I need some more activity to rank up)!
Escaping {} surrounding a variable to be formatted
I need to generate a string where the variable should end up between {}. For instance, the result should be
How to print a number using commas as hundred separators using python?
num=987756
…
#output 98,77,56