Programming as a career

Message Bookmarked
Bookmark Removed

I've been doing some programming at work, but because it's a hardware place, the bar is set pretty low in terms of languages. I've floated my resume out there a couple times, but aside from a couple nibbles, nothing, so I've realized that I don't have enough CS knowledge: a decent amount of perl, less decent PHP, some Mysql, some Javascript, and a couple of C classes that I've taken a couple years ago that have fallen into disuse. What, then, should I improve on? Should I take some Java classes? I figure that I'll have to take a data structure class sooner or later; should I aim for a certificate or even a degree?

Leee, Friday, 21 August 2009 03:28 (twelve years ago) link

Java and C# are very high in demand. And definitely get a Bachelor's degree in CS if you can. Tons of places won't even give you the time of day if you don't have one.

Mr. Snrub, Friday, 21 August 2009 03:36 (twelve years ago) link

Bump. Anyone else, or did Mr. Burns give the long and short of it?

Leee, Friday, 21 August 2009 21:00 (twelve years ago) link

I've been in this career so long I'm obsolete, so my best advice is look at the want ads for programmers and see what's needed most. And I hope a BS in CS still means you know C inside and out.

nickn, Friday, 21 August 2009 21:27 (twelve years ago) link

Oh, and get the A+ certification. No, it's not very programming-related, but it shows that you know rudimentary knowledge of PC repair, it's a super easy exam, and it's on your resume forever.

Don't bother with most other certifications, though. They're an absolute nightmare to study for and they become obsolete too fast. Instead, I'd start contributing to some free open source project on sourceforge or google code or something, and then bring that code with you to all your interviews. It gives you a good answer to the "yes, but what have you done lately?" question, and voluntarily contributing for a free project makes you look good.

Mr. Snrub, Sunday, 23 August 2009 04:02 (twelve years ago) link

three months pass...

Asking coworkers and family, and two things I often hear:

1. Get at least a bachelor's in comp sci/software engineering (I have an ever-useful English degree already) because in terms of career growth, you won't get priority unless you have that degree. This is important to me, given that I'm currently at a position where I have almost no room for growth.
2. Don't get a bachelor's, because everything's getting outsourced in software engineering anyway.

I'm reluctant to give up before I've even gotten started on programming, since I took forever to find a job, first of all, and one that I actually enjoy.

Leee, Friday, 18 December 2009 05:40 (twelve years ago) link

People who say #2 don't know what they're talking about.

Just make sure you either specialize or diversify your skills (whichever suits your persona, there are pros and cons to either) so you're not a one trick programmer, and you'll be fine. In this late 2009 economapolypse, I'd go with the diversify-yourself-and-learn-a-whole-bunch-of-shit-for-fun angle. Companies will give preference to people who geek out on programming in their spare time, or *ahem* at least can pretend very well that they do.

Sock Puppet Pizza Delivers To The Forest (Sock Puppet Queso Con Concentrate), Friday, 18 December 2009 06:35 (twelve years ago) link

Yeah, learn a bunch of shit, more the better.

kingfish, Friday, 18 December 2009 06:40 (twelve years ago) link

3. Make up for lack of degree w/ experience (fuck going back 2 school)

shartin jort (am0n), Friday, 18 December 2009 06:44 (twelve years ago) link

Other recent observations: open source environment jobs have blossomed.. Microsoft technology jobs have softened (for pretty obvious budget reasons.) It's awesome to know both, but if you had to choose one, choose the former -- since it's free, and if you can prove that you wrestled with bugs in some open source package, and overcame them, that's something you can put on a CV.

(The really stupid thing about tech companies: no one will hire a seasoned C# programmer for a mid-level Java position, or vice versa -- even though the two language skills are highly transferable. This is digressing into rant territory, so I'll stop.)

Sock Puppet Pizza Delivers To The Forest (Sock Puppet Queso Con Concentrate), Friday, 18 December 2009 06:51 (twelve years ago) link

3b. Or at least spend a number of days going through wiki pages on algorithms involving binary search trees, sort algorithms, and abstract data types like stacks, queues, linked-lists, etc. A BS in CS will teach you that and a lot more, but in practice, it's the former stuff that companies really care about. You do need some math skillz to understand the former. learning O-notation is a bonus.

Then again, some companies just want to hire people who like picking things up quickly.

Sock Puppet Pizza Delivers To The Forest (Sock Puppet Queso Con Concentrate), Friday, 18 December 2009 06:55 (twelve years ago) link

Yeah, learn a bunch of shit, more the better.

ehh, having a multidisciplinary cv can be a pain, recruiters don't know what to do with you.

poster x (ledge), Friday, 18 December 2009 10:58 (twelve years ago) link

I'll back the assertion that it is possible to be a coder without a degree (my ex is an example - heck he didnt even finish high school) but if you go down that path you gotta know C++, C#, assembly, perl, etc relevant to field language. You have to live and breathe code and *enjoy* doing it. I see people who code like other people play and write songs on guitars. Theyre the ones who do well.

millivanillimillenary (Trayce), Friday, 18 December 2009 11:12 (twelve years ago) link

i would think with that trayce you kinda have to get a bit lucky, and find a company that's a bit more relaxed in their recruitment drive.

i recently applied for a java role, having a rather great bouncy interview and selling my enthusiasm for coding etc. They seemed impressed and I thought i'd done well but the other guy won the job basically because he knew more about 'business' terms.

all companies are different, worth researching them individually for your applications.

bracken free ditch (Ste), Friday, 18 December 2009 11:21 (twelve years ago) link

Games industry is perhaps a unique beast compared to coding in all other fields, as it is a lot more of a "prove yer shit" industry.

millivanillimillenary (Trayce), Friday, 18 December 2009 11:57 (twelve years ago) link

Know this really well.

Then this.

And then this.

Now you're pretty much all set.

Mr. Snrub, Friday, 18 December 2009 12:01 (twelve years ago) link

xp Trayce, yeah agree with that

bracken free ditch (Ste), Friday, 18 December 2009 12:14 (twelve years ago) link

Is learning C++ a particularly good idea these days? There's got to be a lot more jobs in Java and PHP, at least. Hell, probably even in Ruby and Python. People do argue that you learn so much from programming C++ that it makes other languages much easier to pick up etc, but that doesn't seem to me like a good enough reason to start there.

Guess it depends on the job you want -- I imagine the places where they use C and C++ now are ones where you're most likely to actually need a CS degree.

What do I know -- I just quit my programming job last month and have no idea wtf to do in the future.

Øystein, Friday, 18 December 2009 12:48 (twelve years ago) link

I had heard that C++ had lost out a lot to Java and Visual C++ to C#, and meanwhile C is still going strong for embedded systems, which C++ is largely unsuited to. But I have never been paid to write in any of those languages so I dunno.

When I was last job-hunting I put just about every language I had even basic knowledge of, and a specialist IT recruiter told me it was confusing and I needed to narrow it down. So don't do that.

I suppose that sounds obvious (writing 30-line programs in yr spare time or in lol college != doing useful work on a real major project), but when your core skills - and I'm not sure I have any - are kind of limited and obsolete, and your jobs to date have involved a lot of whatever nobody else wants to do that day but thinks you can pick up as you go...

brett favre vs bernard fevre, fite (a passing spacecadet), Friday, 18 December 2009 13:23 (twelve years ago) link

I have a good front-to-back knowledge of web development, from html to java, and i do put it all on my cv, but I try to position myself as a java developer. Still most of the stuff i get from agents is for entry level html crap. Basically all agents are know-nothing cunts.

poster x (ledge), Friday, 18 December 2009 13:48 (twelve years ago) link

is it worth learning to use stuff like eclipse and that because i guess while most people can do java C++ fewer people will know how to work with the specfic development tools etc?

I sb'ed your mum (ken c), Friday, 18 December 2009 16:37 (twelve years ago) link

It might also be helpful to learn about recursion, as told by H.P. Lovecraft:

http://www.bobhobbs.com/files/kr_lovecraft.html

o. nate, Friday, 18 December 2009 17:47 (twelve years ago) link

3. Make up for lack of degree w/ experience (fuck going back 2 school)

I kind of sort of have this covered at my current position, but I'm sort of an ad hoc backwater one-person band supporting a group in a hardware company, so there's not a lot of support for me but also not a lot of priority given to me vis-a-vis promotions, accumulating job skills past a rudimentary point, etc. It's good for financial security, but if I need/want a real developer's job, I feel a bit underqualified, thus thinking about doing school part time to get a BA/BS. And that goes to Sock Puppet's 3b; I'm a bit intimidated by the mathier stuff on my own, I do much better in a classroom.

I have some Java on me now, I'm taking a C++ class at jr. college this Winter Q.

Leee, Friday, 18 December 2009 21:22 (twelve years ago) link

People who say #2 don't know what they're talking about.

Re: outsourcing -- does it matter that I work in Silicon Valley? I tend to assume that if the general trend is towards outsourcing programming, SV would be the place where it happens first.

Leee, Friday, 18 December 2009 21:24 (twelve years ago) link

is it worth learning to use stuff like eclipse and that

i guess it'd be a good idea to know how how yer basic ide works but no point going out of your way to learn any particular one. once you know one you know them all, more or less.

poster x (ledge), Friday, 18 December 2009 21:32 (twelve years ago) link

OTM. Every company has their own specifics w.r.t. IDEs so it's probably not a good use of your time to worry about the environment outside of what you need to know to get things done.

There's no concrete answer to the get/don't get a C.S. degree question. As you might have guessed already it depends... amount of experience, depth of background, relative visibility, the type of job you're looking for and what industry it's in (something like game development is it's own Universe). I can only offer up anecdotes from my own career - I've had exactly two formal programming classes, but 18 years of job experience from IT garbage collector, to webmaster, device driver wizard, and database king. Like everyone else has been saying, have a broad familiarity with a couple areas of deep knowledge. If I was starting now, I'd make Java one of those deep knowledge areas.

Also, don't underestimate visibility. Write some code, improve on it, and then blog the results. Write comments on someone else's coding blog. I've gotten a couple of contract gig offers just because I posted some sample code to my blog. Go figure.

Lastly, get familiar with database basics. Nothing ridiculous like Oracle but just your basic MySQL/PostGreSQL fundamentals. I didn't set out to be a database guy, but I knew some stuff and now four years later I'm a full-blown DBA and pretty good at it.

Elvis Telecom, Saturday, 19 December 2009 00:25 (twelve years ago) link

> I had heard that C++ had lost out a lot to Java

i think this is due to a shift towards webapps (java servlets). i'm a dyed in the wool c programmer now doing java for a living because everything is now sat on a server being served by JBoss.

(never had a lesson in java, hadn't been invented whilst i was in education... lol, z80)

i am aghast at some of the job adverts i see, the list of disparate things they expect you to know. but a lot of this is due to agency idiots. (that said, if i think about all the disparate things i use at work...)

the thing they don't teach you at college but is fundamental when working professionally and/or in groups is version control. get comfortable with cvs or svn or maybe even git. at the very least know what they do.

i'd also recommend having something you can show people, like contributing, or starting, an open source project. or just having some flashy applets somewhere.

this stuff all takes years, 25 years in i'm still picking stuff up.

koogs, Sunday, 20 December 2009 10:27 (twelve years ago) link

Hm, I like a syntax-highlighting text editor with parenthesis matching and suchlike, but for the actual business of compiling and running I'm still alt-tabbing to a console window, guess I'd better stop being so afraid of letting the IDE take care of it...

Ha, agency job ads. Seen ads asking for 3 years' experience in technologies which aren't 3 years old.

This is good encouragement to actually listen to the woman who's been trying to get us all to use svn. The only version control I've used was command-line only and didn't do much beyond locking the file and adding a timestamped comment. Seems they're a lot more sophisticated now.

brett favre vs bernard fevre, fite (a passing spacecadet), Monday, 21 December 2009 16:32 (twelve years ago) link

file locking is so '90s.

poster x (ledge), Monday, 21 December 2009 16:37 (twelve years ago) link

Hm, I like a syntax-highlighting text editor with parenthesis matching and suchlike, but for the actual business of compiling and running I'm still alt-tabbing to a console window, guess I'd better stop being so afraid of letting the IDE take care of it...

Yeah, I programmed in notepad etc for years, before moving to a proper IDE, mostly because I figured I should learn to program without any tools to help me out. In hindsight that wasn't a particularly good idea, it just made thinks more convoluted and slow. Rewriting code was a major pain etc.
Learning an IDE (Eclipse, for instance) is hardly any work at all, since you can start off treating it as little more than a fancified text-editor, and learn the cool tricks as you go along. I mean, hell, I'd used one for over a year before I even heard of "extract method"! Sheesh.

Actually, that reminds me that getting comfortable with Maven or Ant is fairly quickly done, and something well worth doing once you're comfortable with Subversion (SVN) or CVS.
Also, testing frameworks. JUnit if you're using Java. It's both quick to learn, and well worth it; just don't let the annoying Test-Driven Design (TDD) fanatics put you off.

Øystein, Monday, 21 December 2009 18:15 (twelve years ago) link

there are things netbeans cannot do that easily vim will do in a heartbeat but i can't live without the code completion stuff as i don't really know the libraries (and they change). plus java projects have such a deep directory trees and our stuff is so scattered that you end up spending most of your time in vim typing directory paths to swapping between files (could use ctags i guess)

eclipse i never got to grips with - there's no 'compile' button as it's continually compiling and i like having a compile button.

svn can be used on the command line but we use tortoise.

koogs, Monday, 21 December 2009 19:11 (twelve years ago) link

four years pass...

Programmers are the magicians of the modern age

calstars, Sunday, 8 June 2014 21:36 (eight years ago) link

Not the ones I've known. And I've known more than a few.

Aimless, Monday, 9 June 2014 04:56 (eight years ago) link

buncha putzes

j., Monday, 9 June 2014 05:09 (eight years ago) link

Programming is the worst

Nhex, Monday, 9 June 2014 06:46 (eight years ago) link

DevOps is the worst.

koogs, Monday, 9 June 2014 10:32 (eight years ago) link

Software Engineer USA™

, Monday, 9 June 2014 16:04 (eight years ago) link

we like to pretend we're architects and engineers and builders but we're really more like apprentice mechanics or those dudes that assemble pre-made furniture half the time

a strange man (mh), Monday, 9 June 2014 16:07 (eight years ago) link

programming is great if functions and syntax are well documented. it is the worst thing imaginable otherwise.

sufi john paxson (Sufjan Grafton), Monday, 9 June 2014 16:09 (eight years ago) link

I do enjoy the critical thinking parts of my mind that were unlocked by learning CS theory and programming over a period of time, but it really chafes me to see software developers think that they're able to solve non-software societal problems with that toolkit

a strange man (mh), Monday, 9 June 2014 16:09 (eight years ago) link

professional googlers

lag∞n, Monday, 9 June 2014 16:10 (eight years ago) link

Oh, I forgot that one. Software Architect. Classic.

I much rather SysAdmin, coder, developer, webmonkey/webmaster, script kiddie

Mind you, my end goal is probably to be a 'Software Architect', so I should lol carefully

, Monday, 9 June 2014 16:10 (eight years ago) link

yeah, really smart or tricky code makes you seem like a wizard but what it really makes you is an asshole if it's ever meant to be maintained

pretty sure my coding style has gotten progressively dumber on purpose

a strange man (mh), Monday, 9 June 2014 16:10 (eight years ago) link

^^ thank you

sufi john paxson (Sufjan Grafton), Monday, 9 June 2014 16:11 (eight years ago) link

I think software/systems architect is a fine title, even if my actual designs-buildings-and-structures friend recoils in disgust. I hate when people introduce themselves as "architects" without the qualifier.

Now, the part of the business where people use "architect" as a verb... not so good.

a strange man (mh), Monday, 9 June 2014 16:12 (eight years ago) link

I do enjoy the critical thinking parts of my mind that were unlocked by learning CS theory and programming over a period of time, but it really chafes me to see software developers think that they're able to solve non-software societal problems with that toolkit

― a strange man (mh), Monday, June 9, 2014 5:09 PM (1 minute ago) Bookmark Flag Post Permalink


From the dudes I've met, I get the impression many of them think they do have superpowers and can basically write a piece of software/webapp to solve just about any social/civic/political issue

, Monday, 9 June 2014 16:12 (eight years ago) link

they probably also think they can throw together that application in a matter of a few days

programmers are horrible estimators

a strange man (mh), Monday, 9 June 2014 16:13 (eight years ago) link

working with computers makes people feel very powerful because computers are powerful

lag∞n, Monday, 9 June 2014 16:13 (eight years ago) link

bring back punch cards

sufi john paxson (Sufjan Grafton), Monday, 9 June 2014 16:14 (eight years ago) link

ya, it's just funny because in canada you're not really allowed to use "software engineer", because, well, you're not an engineer. but in the states, it's quite common

, Monday, 9 June 2014 16:15 (eight years ago) link

wait what's the 3 panel diff, I only have the file tree (which I actually welcome, find it really useful) and the file changes

even the birds in the trees seemed to whisper "get fucked" (bovarism), Friday, 8 April 2022 23:11 (two months ago) link

my monitor is like 22" or something and that seems plenty. the one at work is ridiculous, like 32" or more and people do have trouble with those when sharing on zoom because nobody can read anything

even the birds in the trees seemed to whisper "get fucked" (bovarism), Friday, 8 April 2022 23:11 (two months ago) link

> wait what's the 3 panel diff...?

it's literally the three panels you go on to describe! it used to be only the two files side by side (which was narrow enough) but the file tree now takes a third of the screen.

oh, maybe you're using the combined diff, not the side by side version, there's an option

and i hadn't spotted the slightly cryptic button to hide the file tree, so that might help, thanks

no external monitor just the one built into 15" laptop

koogs, Saturday, 9 April 2022 02:51 (two months ago) link

yeah it's not side by side, just vertical, but that must be the default option because I've never changed anything on it, didn't even know there was a side-by-side diff tbh

even the birds in the trees seemed to whisper "get fucked" (bovarism), Saturday, 9 April 2022 13:49 (two months ago) link

this youtube channel is pretty hilarious

https://www.youtube.com/watch?v=Uo3cL4nrGOk

https://www.youtube.com/watch?v=bXzTXD_OJo0

Punster McPunisher, Saturday, 9 April 2022 20:56 (two months ago) link

I quite like reviewing in Github by pressing . to open the VSCode online editor - it’s much easier to see what‘s going on in a PR IMO.

Chewshabadoo, Sunday, 10 April 2022 15:50 (two months ago) link

this youtube channel is pretty hilarious

favourite lines are from the C++ dev: "runtime error detection is the programmer's responsibility", "we need to see the compiler as...enemy"

TWELVE Michelob stars?!? (seandalai), Sunday, 10 April 2022 22:08 (two months ago) link

two months pass...


names = ("name1", "name2")\
if os.environ['ENV'].lower() == 'test' else ("name1",)

python code it is, readable if yoda you are.

koogs, Wednesday, 15 June 2022 12:32 (two weeks ago) link

I'll have chicken if it's cheap, otherwise I'll have chips.

The linebreak seems unnecessary. Oh no it's over 80 characters long, aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaargh!

dear confusion the catastrophe waitress (ledge), Wednesday, 15 June 2022 13:49 (two weeks ago) link


i'll have chicken and chips
if it's cheap else i'll have chicken

then-if-else, as nobody calls them

koogs, Wednesday, 15 June 2022 14:12 (two weeks ago) link

eh, i don't think `a if cond else b` is significantly more/less readable than any other ternary syntax, e.g. `cond ? a : b`.

𝔠𝔞𝔢𝔨 (caek), Wednesday, 15 June 2022 16:16 (two weeks ago) link

I dislike the original because I like the default condition first and having test as the default is uh, safer but not what I'd do

mh, Wednesday, 15 June 2022 16:22 (two weeks ago) link

I think if/then/else syntax has absolutely trained developers of a certain age (e.g., me) to expect to see the condition first; that Python excerpt reads like someone said "my code would flow much better if it was arranged like German verbs or Spanish adjectives" and I'm getting irrationally angry about it (also I have never looked at or written Python code in my life).

castanuts (DJP), Wednesday, 15 June 2022 16:33 (two weeks ago) link

the ?: is odd because of the use of only punctuation. and how do you nest them? it's probably ok if the bits are short, or indented correctly


thing = (v_one == v_two)
? same
: different

with 'a if cond else b' there's more chance that the condition is further to the right than i like, and => easier to miss. i guess he moved the if onto the second line to make it clearer, but made it worse - it looks like another, badly indented, statement,

> developers of a certain age

it me

> having test as the default is uh, safer

i may've flipped the logic whilst anonymising it for posting

actually, i guess this would work


thing = safe_default
if (rare condition)
thing = special case
end

which looks a lot like the original but is in fact the opposite. maybe that's my issue with it

koogs, Wednesday, 15 June 2022 17:00 (two weeks ago) link

this is baffling to me.

i don't think appeals to english word order make sense when talking about programming languages 1. this is not applescript 2. plenty of programmers are not native english speakers. 3. english word order is very flexible.

but to the extent they do: "x is y if condition, otherwise it's z" doesn't seem like non-english word order at all. it's idiomatic english.

if the argument is that this is unintuitive (hard to read?) for non-python programmers, i think that applies more to ternary operator syntax in every language that uses random punctuation like ? and :

if you really want a ternary one-liner with the condition first a la js, replace ? with "and" and : with "or", i.e. x = condition and y or z. this obviously sucks, but no more than random punctuation.

𝔠𝔞𝔢𝔨 (caek), Wednesday, 15 June 2022 17:27 (two weeks ago) link

koogs i feel like your complaint is with ternary, not with the python syntax for ternary.

𝔠𝔞𝔢𝔨 (caek), Wednesday, 15 June 2022 17:28 (two weeks ago) link

I think it's not english word order, it's just convention and the programming languages/syntax I'm used to using.
I was looking at some python a coworker wrote and it was obviously written by someone used to C#. It's just idiomatic. I'd say over half of scanning over code and thinking you know what's going on is down to convention and not enforced language structure

that said,
the ?: is odd because of the use of only punctuation. and how do you nest them?
I got so used to parsing these in my brain that it'd disgusting. Mostly due to coworkers doing
var x = condition ? condition 2 ? a : b : c

I haven't done that or read through that in a few years so please clown me if I botched it

mh, Wednesday, 15 June 2022 17:41 (two weeks ago) link

fwiw you are only truly a savage if you start doing one convention in a project that completely uses another (while others are still working on it) or if you just do your conditionals a bunch of different ways for no conceivable reason

mh, Wednesday, 15 June 2022 17:42 (two weeks ago) link

it's more to do with putting the important information first.

let thing = "some value" if (whatever)

this is an assignment. oh, but it's conditional. i would've preferred to know that first. i basically want to read as little as possible of the line before i can decide whether it's important or not.

throw massive exception (argh!) if appropriate (oh...)

koogs, Wednesday, 15 June 2022 17:49 (two weeks ago) link

var x = condition ? condition 2 ? a : b : c

yeah my reaction to this is mostly: if you think ternaries in python are bad, wait until you see how people use them in practice in js.

throw massive exception (argh!) if appropriate (oh...)

i get your point but fwiw you can't throw in a ternary.

𝔠𝔞𝔢𝔨 (caek), Wednesday, 15 June 2022 18:18 (two weeks ago) link

code review today (please excuse clumsy anonymising)


...
.withXXXXXXXXXXXXStartTime(OffsetDateTime.parse((somethingInfo.getXXXXXXXXXXXXStartTime() == null) ? XXXXXXXXXXXXX_START_TIME : DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss'Z'").withZone(ZoneId.of("UTC")).format(Instant.EPOCH.plus(somethingInfo.getXXXXXXXXXXXXStartTime()))))
...

kids today with their 300 character-wide monitors

koogs, Thursday, 16 June 2022 16:59 (two weeks ago) link

yeeeikes

𝔠𝔞𝔢𝔨 (caek), Thursday, 16 June 2022 17:27 (two weeks ago) link

> if you think ternaries in python are bad, wait until you see how people use them in practice in js.

or java...

koogs, Thursday, 16 June 2022 17:34 (two weeks ago) link

koogs, when did you start maintaining my old code from a decade ago

mh, Thursday, 16 June 2022 18:24 (two weeks ago) link

actually, more like fifteen years ago. me old

mh, Thursday, 16 June 2022 18:25 (two weeks ago) link

Is there a data science thread? I’ve found myself managing some data scientist on a pretty cool project but I am completely out of my league. I work in geography (English major here!) and I’ve been on the job for awhile so I can at least act as an SME but these kids are doing some insane stuff.

Heez, Thursday, 16 June 2022 20:25 (two weeks ago) link

we should start a real one. we’ve just been bouncing between this one and caek’s corner iirc

mh, Thursday, 16 June 2022 21:03 (two weeks ago) link

in my review i suggested moving the 300 character line of code into a separate method and calling that instead.

he duly copied the line verbatim into another method, so there's now a new method with a single 300 character line in it...

koogs, Friday, 17 June 2022 10:36 (two weeks ago) link

Programmers gonna literal.

Chewshabadoo, Friday, 17 June 2022 10:48 (two weeks ago) link

lmao

castanuts (DJP), Friday, 17 June 2022 14:52 (two weeks ago) link

Classic!

Jimmy Jimmy Loves Mary-Anne Mary-Anne (James Redd and the Blecchs), Friday, 17 June 2022 14:55 (two weeks ago) link

I don't think I've ever typed this out before but one thing I haven't forgotten over many years is someone once saying about someone else "he really is an automaton."

Jimmy Jimmy Loves Mary-Anne Mary-Anne (James Redd and the Blecchs), Friday, 17 June 2022 14:56 (two weeks ago) link

regexp help. need at least 1 of A B and C, in order

9A9B9C
9A9B
9A9C
9B9C
9A
9B
9C
are all ok (where 9 is any digit). blank is not

so far i have

/^(9A9B9C|9A9B|9A9C|9B9C|9A|9B|9C)$/

which reduces down to

/^(9A(9B9C|9B|9C|)|9B(9C|)|9C)$/

there's slightly more to it than this but this is the crux

koogs, Monday, 20 June 2022 16:08 (one week ago) link

no reason it has to be one line, of course.

koogs, Monday, 20 June 2022 16:30 (one week ago) link

since we got on Java 8 there's been like a competition to see who can make the most convoluted lambda expression possible, I hate it cuz these are so hard to debug

our transfer objects go like 6 layers deep. yeah a bunch of nested if loops looks like crap but you can at least step through it and easily make changes. we have a new developer on one of them now, I can only imagine how much he'd struggle if I did things the way everyone else was

frogbs, Monday, 20 June 2022 17:46 (one week ago) link

Koogs, I’m not great at regex but I find the editor at regexr.com quite useful- lots of user submitted patterns too that can be lifted and adapted

she started dancing to that (Finefinemusic), Monday, 20 June 2022 18:31 (one week ago) link

i don't think we'll ever use more than one of A, B or C, so it'd just be 9b;ABCd; if i had my way.

(will that work?)

koogs, Monday, 20 June 2022 20:24 (one week ago) link

no.


9[ABC]

koogs, Monday, 20 June 2022 20:25 (one week ago) link

lol java 8, they’re on 17 now bruv

(8 is fine, I crack up that they finally did a version release strategy but it’s a major number so often)

mh, Tuesday, 21 June 2022 01:30 (one week ago) link

last 3 components i worked on here were 2014 vintage and needed Java 8, wouldn't compile under (our default) Java 11. i didn't upgrade them.

Been downhill all the way with Java since they introduced lambdas.

koogs, Tuesday, 21 June 2022 01:37 (one week ago) link

beginners mindset, you’re worse than a weird .net bro now

mh, Tuesday, 21 June 2022 01:40 (one week ago) link

That sounds like a very difficult thing to do in regex, but fairly simple in regular code.

o. nate, Tuesday, 21 June 2022 17:29 (one week ago) link

lol java 8, they’re on 17 now bruv

yea we recently upgraded to 11, idk when we'll ever get to 17. i mean what's the point

frogbs, Tuesday, 21 June 2022 17:47 (one week ago) link

I think I'd just do /^(9A)*(9B)*(9C)*$/ and check not empty/null separately tbh?

I'm assuming that checking for empty string is like one brief, readable line despite my suspicions about Java. I might not be understanding the requirements correctly though and my regexping is rusty.

(tbh I am rustier than ever at programming in general, which I was never good at, and I feel like my days at my current job are numbered because my brain seems to have died and we're implementing a new system I don't understand or care about understanding at all. Sort of feel I should completely give up on making a living doing anything tech-related but can't think of what else I might possibly do. I remember saying all this before, almost exactly half my lifetime ago at the start of my non-career, and probably on this thread several times since then...)

(Current job is in theory part scripting and part support, and the support part expands to fill 99.9% of the time. That's what support jobs are like, right? But also I let it do so, because I always put off any tasks which require
1. concentration/flow/clear-headed thought/forward planning
2. the perceptivity to think of all the possible disastrous problems and guard against them
3. the calmness not to stress yrself to death thinking about what examples of 2 you've forgotten and how much of the database it might delete and how your coworkers will hate you and the boss will thunder down the hall going "WHICH IDIOT LET THIS HAPPEN", again)

a passing spacecadet, Tuesday, 21 June 2022 18:31 (one week ago) link

I think I'd just do /^(9A)*(9B)*(9C)*$/ and check not empty/null separately tbh?

This works from what I can tell, and the only suggestion I'd make is to not bother with capturing them if that's needed:

/^(?:9A)*(?:9B)*(?:9C)*$/

Antifa Lockhart (Leee), Tuesday, 21 June 2022 18:43 (one week ago) link

it's ruby, but that doesn't matter.

i went with readability in the end, listed all the valid combinations in separate lines. you can golf these things but there's a point where concise becomes curt and that's everything i don't like.

but wouldn't /^(9A)*(9B)*(9C)*$/ allow 9A9A9A9A? i can only have at most one of each. replacing the *s (0 or more) with ?s (0 or 1) should do. then, yes, just need to catch "" separately

koogs, Tuesday, 21 June 2022 20:46 (one week ago) link

as for fuckups, we have two components, A (currently on version 367) and B (currently on version 317) and i managed to deploy version 317 of component A to LIVE and didn't notice for an ENTIRE DAY. this is public facing stuff, 10s of thousands of users and not a single bug report or alert. so either nothing important has happened in those last 50 versions or all the built-in redundancy works.

(i've added checks so it won't happen again - it'll now look up the version itself)

koogs, Tuesday, 21 June 2022 20:55 (one week ago) link

but wouldn't /^(9A)*(9B)*(9C)*$/ allow 9A9A9A9A? i can only have at most one of each.

Sorry, yes, it would - I misread "at least 1 of A, B and C" to mean that repeats were OK as long as A-B-C were still in order.

Probably something to be said with listing the valid combinations separately for readability, though. As long as it doesn't result in such a massive list nobody will ever read the whole thing...

a passing spacecadet, Tuesday, 21 June 2022 21:20 (one week ago) link

maybe i'm missing something but isn't it just A.*B.*C
haven't done regex in ages

adam t. (abanana), Friday, 24 June 2022 17:01 (one week ago) link

never mind

adam t. (abanana), Friday, 24 June 2022 17:04 (one week ago) link


You must be logged in to post. Please either login here, or if you are not registered, you may register here.