Details
-
AboutLiving and working in Spain, originally from Scotland.
-
Skillsc#, js, c++, python
-
LocationCosta Blanca, Spain
-
Github
Joined devRant on 9/7/2016
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
-
That moment where you see code of someone who riddles their code with nested if-else and if-elseif statements.
I don't remember writing an else statement for years. It almost always can be avoided (and the rare cases where it makes sense I prefer the switch statement).
Yet I never grasp why people do:
```
if(someCondition) {
// huge nested code block
} else {
throw new Error();
}
```
Instead of
```
if (!someCondition) {
throw new Error();
}
// continue in the normal scope
```
And then we have experts that like doing:
```
if(someCondition) {
if (bar) {
$foo = 'narf';
} else {
$foo = 'poit';
}
// huge code block
if($foo == 'narf') {
if(yetAntherCondition) {
// huge code block
} else {
throw new Error();
}
// huge code block
} else {
throw new Error();
}
} else {
throw new Error();
}
```
Help!
If ever was to design a programming language, I'd forbid the `else` and `elseif` keywords. I have yet to find an instance where I could not replace some `else` by either a guard or an early return or introducing some polymorphism.1 -
Created a batch file to modify some system files on our embedded system.
Accidentally double clicked it in my development main machine :(
Man, fm fucking l2 -
I received this from a recruiter. I can't handle the number of syntax errors. Who is it a appealing to :/4
-
Netbeans is like the girl you pull at 3am in the kebab shop. You wouldn't brag about it, its bloated and bug ridden but it gets you there without having to shell out any more money.2
-
The stress that comes from meeting deadlines, and always trying to keep the behavior/logic of what your working on straight.
-
[on any forum hosting the very question that keeps you awake at night] I'll come back to explain how it was solved!
-
Worst part of being a dev?
For me it's putting myself into infinite loops wrestling with my own self doubt. Is this really how I want to solve this problem? Could this code be cleaner? Surely there's a better way to do this? Am I adding unnecessary complexity? Is this going to come back and bite me in x months? And so on...
In fact, most days I just feel like an imposter.4 -
Worst part of being a dev? Ever got an error message without a corresponding stack overflow question/awnser?1
-
If literally anything in our system stops working the supervisor's immediate response, regardless of whether it makes sense or not is to tell us to clear the browser cache. There are circumstances where that drives me absolutely up a wall.
-
a U.S. company that places an order for 100,000 integrated circuits with a Japanese manufacturer. Part of the specification was the defect rate: one chip in 10,000. A few weeks later the order arrived: one large box containing thousands of ICs, and a small one containing just ten. Attached to the small box was a label that read: "These are the faulty ones."3
-
!rant
Anybody here heard of Project Euler? It's a series of maths/programming puzzles, and I think it's great fun trying to solve them. 😁6 -
I've just realised that whenever i want to go on Google Analytics I've just been typing anal and hitting enter 😅13
-
Username changes should be a feature. Especially after changing jobs, or just wanting a change. Dangerous app this. Brilliant. But dangerous!9
-
Real programmers don't comment their code. It was hard to write, it should be hard to understand.24
-
At the end of side job customer asked if I could add one feature for double the money.
Did it in 1min and with 3 loc. Best deal ever made ;)7 -
Me: Fix this for me and I'll send you a cookie.
Collegue: Deal!
(5 mins later)
Collegue: Done, give me cookie.
Me: send MUIDB4T.txt ..... Long cookie file on Skype.
( Munches chocolate chip cookie)
(Collegue stares in disbelief....)
Me: hey I Even gave you a big one.
( Passes cookie jar )1