原创 The case of the unconventional programmer

2014-5-9 14:13 1308 21 22 分类: 消费电子

There are engineers and programmers who insist on marching to their own peculiar drums. Sometimes that can be a good thing, but for managers it can be a complete nightmare.

 

One of my team members was a very quirky character, which also translated into his style of coding.

 

On one project, we were writing a somewhat large embedded code in ARM, with more than 60 modules. Instead of adhering to our common style, he insisted on doing it his way.

 

At a certain point, I gave him the task to design several complex data entry screens, with a particular "look and feel" to communicate over our dumb terminal interface.

 

After leaving him at it for a month, I went over his code to peer review it. I was absolutely astonished. All his screens -- very complex, context-sensitive screens -- were contained in a single printf() statement.

 

He wrote the longest printf call I had ever seen in my entire life. The line was 1,450 characters long!

 

It was constructed with ternary operators like {"%s%s%s%s.....%s%s", a > 2 ? b < c ? "this" : "that" : f == 0 ? ......}. Just imagine a line with more than 8 layers of logic, over 60 extremely complex ternary operators, spanning over 1,400 characters in a single printf() evaluation.

 

It worked, but I presumed that it would be impossible to maintain. I trashed his work and asked him to redesign it from scratch.

 

It was very tense, and we argued intensely, but he ended up doing it right in the end. He was a brilliant engineer, actually.

 

Jonny Doin is CEO of GridVortex Systems. He has over 25 years experience working with embedded systems R&D and hardware and firmware design. He has worked on medical, broadcast video, industrial, and energy applications and founded GridVortex in 2012 to design and deploy IoT intelligent networks for large-area urban projects and embedded micro-clouds.

文章评论1条评论)

登录后参与讨论

用户1406868 2015-12-18 02:50

Thanks Victoria I like the photo of you, it is very natural and shows you in a relxead and friendly setting, just being you! Sending our love and hoping you will soon be back home x

用户1152031 2014-1-14 09:22

顶!
相关推荐阅读
用户3813345 2016-03-14 18:57
Examining binge work
The Wharton School recently published an article that examines how the youngest full professor at ...
用户3813345 2016-01-21 17:50
Modern-day engineering notebooks
For engineers and scientists, notebooks are a reliable means to document their ideas, inventions, ...
用户3813345 2015-09-11 21:16
Boost your engineering value in only 20 mins a day
My aim is to boost your value in only twenty minutes a day. That is the amount of time that commer...
用户3813345 2015-08-29 23:17
Analogue rules supreme: Scientifically proven
My first job fresh from college was testing and debugging control loading system...
用户3813345 2015-08-28 22:09
Meetings will persist until morale improves
A snippet in the life of a cubicle rat.....   Ask any engineer about the biggest time-w...
用户3813345 2015-08-28 19:31
Hacking: Just another stage of tech life cycle?
Amid a huge number of recent news stories about systems getting hacked I read several in the area ...
我要评论
1
21
关闭 站长推荐上一条 /2 下一条