0

Please how can I solve an IndentationError :expected an indented block

I want to print out a string but it shows the above error

31st May 2019, 7:16 PM
EPHRAIM YUSUF
EPHRAIM YUSUF - avatar
3 Answers
+ 2
EPHRAIM YUSUF hi, Please link the code here for fast solution. Indention error is come in python when you are not indent means properly give space after using any function, conditional statement to remove that just give some space after that function or conditional statement Have these 🍎 🍎 🍎 🍎 🍎
31st May 2019, 7:23 PM
DishaAhuja
DishaAhuja - avatar
0
Can you post your code? it sounds like you did not properly format your code, indentation is important in python, it’s the spacing in lines of code(TAB) if you declare a function, for example: def hello(): any code that belongs to that function must be indented as so: def hello(): <-declared new function print(“hello”) <-belongs to function hello() <- calls the function(no space)
31st May 2019, 7:30 PM
Jake
Jake - avatar
0
anything under a function, loop, conditional (anything with a colon at the end) must be indented. Python hates braces 😁
1st Jun 2019, 4:05 AM
Choe
Choe - avatar