Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,143,187 members, 7,780,298 topics. Date: Thursday, 28 March 2024 at 11:54 AM

Programming Is Nothing Without If & Else Prove Me Wrong - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / Programming Is Nothing Without If & Else Prove Me Wrong (886 Views)

Prove Me Wrong If You Can! / Programming Is just Like Playing Football / Programming Is Not Fun And To Make It Fun (2) (3) (4)

(1) (Reply) (Go Down)

Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 3:59pm On Aug 01, 2022
Programming is nothing without If & else
Prove me wrong
Re: Programming Is Nothing Without If & Else Prove Me Wrong by spartan117(m): 6:34pm On Aug 01, 2022
What's this undecided

Re: Programming Is Nothing Without If & Else Prove Me Wrong by valzey(m): 7:30pm On Aug 01, 2022
This is like saying programming is nothing without logic. Isn't it obvious? Does it have to be said?

1 Like

Re: Programming Is Nothing Without If & Else Prove Me Wrong by namikaze: 7:42pm On Aug 01, 2022
dodgelord:
Programming is nothing without If & else Prove me wrong
Smiles in pattern matching.

2 Likes

Re: Programming Is Nothing Without If & Else Prove Me Wrong by Nobody: 10:32pm On Aug 01, 2022
Ever heard of something called switch?
grin

2 Likes

Re: Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 11:19pm On Aug 01, 2022
GREATIGBOMAN:
Ever heard of something called switch?
grin
yes boss
Re: Programming Is Nothing Without If & Else Prove Me Wrong by Nobody: 11:27pm On Aug 01, 2022
dodgelord:
yes boss

Explain what it does
Re: Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 11:29pm On Aug 01, 2022
GREATIGBOMAN:


Explain what it does
Alternative to if else statement na.

Lolz. Boss u thought i dont knw coding? grin
Re: Programming Is Nothing Without If & Else Prove Me Wrong by Nobody: 11:32pm On Aug 01, 2022
dodgelord:

Alternative to if else statement na.

Lolz. Boss u thought i dont knw coding? grin


I wanted you to prove yourself wrong.

U can close the thread now
wink

2 Likes

Re: Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 11:35pm On Aug 01, 2022
GREATIGBOMAN:



I wanted you to prove yourself wrong.

U can close the thread now
wink
use ur brain na

1 Like 1 Share

Re: Programming Is Nothing Without If & Else Prove Me Wrong by emetisuccess(m): 9:01pm On Aug 02, 2022
dodgelord:

Alternative to if else statement na.

Lolz. Boss u thought i dont knw coding? grin

It's not just alternative to if and elseif.
For proper usage of switch and if/elseif statement
Switch statement is used when dealing with single input i.e when getting single input from the users. Example, from a select element with options.
While, if and elseif statement deals with getting multiple input from users, i.e comparing users data and printing the result according to the logic.

Note, both can be used for the same thing. But for best practice, it's what I wrote up there. Thanks �.

1 Like

Re: Programming Is Nothing Without If & Else Prove Me Wrong by ConversionSpree: 9:57am On Aug 03, 2022
If you are familiar with Python well enough, you would understand that you can in fact do without the Else statement. IF does a better job as a conditional statement than Else. I mean, the Else is cool but too much of it is way too redundant, making your code unnecessarily long and messy to read. You don't want that.

Use the Else statement sparingly, and only when it's necessary.
Re: Programming Is Nothing Without If & Else Prove Me Wrong by BeLookingIDIOT(m): 5:28pm On Aug 03, 2022
dodgelord:
Programming is nothing without If & else
Prove me wrong
Switch statement
Ternary operator
Pattern matching
Jump table
You could even use 'try' and 'catch' and looping statements with a little creativity.

You're such a novice.

2 Likes 1 Share

Re: Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 5:47pm On Aug 03, 2022
BeLookingIDIOT:

Switch statement
Ternary operator
Pattern matching
Jump table
You could even use 'try' and 'catch' and looping statements with a little creativity.

You're such a novice.

Yea. I am a newbie. Open to learn tho
Re: Programming Is Nothing Without If & Else Prove Me Wrong by RepoMan007: 6:32pm On Aug 03, 2022
If else can be circumvented with "while" and "do while" statements.
Re: Programming Is Nothing Without If & Else Prove Me Wrong by Jagaban50: 6:59am On Aug 05, 2022
BeLookingIDIOT:

Switch statement
Ternary operator
Pattern matching
Jump table
You could even use 'try' and 'catch' and looping statements with a little creativity.

You're such a novice.

People don go far, leave us behind, boss abeg I have been trying to learn programming and now I got stuck in OOP in python, can u please help me out sir
Re: Programming Is Nothing Without If & Else Prove Me Wrong by dodgelord: 3:45pm On Aug 15, 2022
BeLookingIDIOT:

Switch statement
Ternary operator
Pattern matching
Jump table
You could even use 'try' and 'catch' and looping statements with a little creativity.

You're such a novice.
yes na. I am a novice. ... u re right

1 Like 1 Share

(1) (Reply)

Who's Good At C++? / Introduction To Programming: It's Hard HELP / Project Topic

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 17
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.