Skip to content

Commit 04f8636

Browse files
authored
Merge pull request #243 from jetbrains-academy/konstantin/fix-edc-1140
Added a more detailed task description
2 parents 74e8cf8 + b1f2c47 commit 04f8636

File tree

1 file changed

+6
-3
lines changed
  • Condition expressions/Single-line if-else statement

1 file changed

+6
-3
lines changed
Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1-
## Single-line if-else statement
1+
As you saw in the previous tasks, a simple `if-else` statement can in fact be written as a single line.
22

3-
As you saw in the previous tasks, a simple `if-else` statement can in fact be written as a single line. Rewrite the statement in the code editor so that it
4-
fits in one line but the results of its execution remain exactly the same.
3+
### Task
4+
Rewrite the statement in the code editor so that it
5+
fits in one line but the results of its execution remain exactly the same:
6+
- If `my_random_number` is greater than 50, the program should print the value of `my_random_number`.
7+
- Otherwise, it should print the message `"Too small!"`.
58

69
For more structured and detailed information, you can refer to [this Hyperskill knowledge base page](https://hyperskill.org/learn/step/5932#simple-if-else?utm_source=jba&utm_medium=jba_courses_links).

0 commit comments

Comments
 (0)