• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 18:50
CEST 00:50
KST 07:50
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
Serral wins HomeStory Cup 2914Serral wins Maestros of the Game 243ByuL, and the Limitations of Standard Play3Team Liquid Map Contest #22: Results and Winners7Code S Season 2 (2026): RO4 and Finals Preview12
Community News
Reynor: GSL Loss Wasn't About Preparation Format12[IPSL] Spring 2026 Grand Finals - This Weekend!1Weekly Cups (July 6 - 12): Protoss strike back11BSL Season 22 Full Overview & Conclusion8BSL Season 22 Full Overview & Conclusion8
StarCraft 2
General
Serral wins HomeStory Cup 29 Weekly Cups (July 6 - 12): Protoss strike back Yamato Cup Series Is the larve respawn broken? Interview with an American 16 Year Old Grandmaster
Tourneys
WardiTV Summer Cup 2026 GSL CK #5 Race War RSL Revival: Season 6 - Qualifiers and Main Event HomeStory Cup 29 Vespene Cup #1 — $300+ USD, July 10
Strategy
[G] Having the right mentality to improve
Custom Maps
New Map Maker - Looking for Advice - Love or Hate Work In Progress Melee Maps [D]RTS in all its shapes and glory <3
External Content
The PondCast: SC2 News & Results Mutation # 534 Burning Evacuation Mutation # 533 Die Together Mutation # 532 Nuclear Family
Brood War
General
Pros Debate: Zerg Unfairly Nerfed? (ASL S22 map) screpdb: new Starcraft reporting tool ASL 22 Proposed Map Pool BSL Season 22 Full Overview & Conclusion BGH Auto Balance -> http://bghmmr.eu/
Tourneys
[Megathread] Daily Proleagues [ASL22] Wildcard Qualifier [IPSL] Spring 2026 Grand Finals - This Weekend! IPSL Spring 2026 Top 4!
Strategy
Fighting Spirit mining rates Simple Questions, Simple Answers Creating a full chart of Zerg builds Relatively freeroll strategies
Other Games
General Games
General RTS Discussion Thread Nintendo Switch Thread Stormgate/Frost Giant Megathread Path of Exile Summer Games Done Quick 2026!
Dota 2
Looking for a Dota Mentor Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Deck construction bug
TL Mafia
TL Mafia Power Rank NeO.D_StephenKing vs This Guy From 1 Million Dance TL Mafia Community Thread Vanilla Mini Mafia
Community
General
US Politics Mega-thread UK Politics Mega-thread Russo-Ukrainian War Thread YouTube Thread Canadian Politics Mega-thread
Fan Clubs
The IdrA Fan Club The HerO Fan Club!
Media & Entertainment
Anime Discussion Thread [Req][Books] Good Fantasy/SciFi books Movie Discussion! Series you have seen recently...
Sports
2024 - 2026 Football Thread McBoner: A hockey love story Tennis[sport] Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023
World Cup 2022
Tech Support
Simple Questions Simple Answers FPS when play League Of Legend on laptop How to clean a TTe Thermaltake keyboard?
TL Community
Northern Ireland Global Starcraft The Automated Ban List
Blogs
Poker (part 2)
Nebuchad
The Experiences We Want and …
TrAiDoS
An Exploration of th…
waywardstrategy
Gauntlet SC2: A Retrospectiv…
Ctone23
ramps on octagon
StaticNine
Funny Nicknames
LUCKY_NOOB
Evil Gacha Games and the…
ffswowsucks
Customize Sidebar...

Website Feedback

Closed Threads



Active: 4779 users

The Big Programming Thread - Page 889

Forum Index > General Forum
Post a Reply
Prev 1 887 888 889 890 891 1032 Next
Thread Rules
1. This is not a "do my homework for me" thread. If you have specific questions, ask, but don't post an assignment or homework problem and expect an exact solution.
2. No recruiting for your cockamamie projects (you won't replace facebook with 3 dudes you found on the internet and $20)
3. If you can't articulate why a language is bad, don't start slinging shit about it. Just remember that nothing is worse than making CSS IE6 compatible.
4. Use [code] tags to format code blocks.
Hanh
Profile Joined June 2016
146 Posts
Last Edited: 2017-06-12 03:23:50
June 12 2017 03:22 GMT
#17761
On June 12 2017 10:10 Manit0u wrote:
It all depends on your uni (obviously, some have better courses than others). I just don't think it's a huge requirement or anything and way too many people think that if they get their CS degree they'll instantly become programmers (you wouldn't believe how many people apply for a job in my company only to learn they can't solve the most basic interview question). I even though about getting an engineer degree but when I solved some of the problems my friend needed help with (he was doing it at the time) I realized that it would just be a waste of every second weekend for the next 3 years just to get the paper. They give people some weird problems and after they get their degree they can't solve basically the only problem we give at interviews:

Write a function (any language, can be pseudocode, doesn't have to be optimal) that gets a string as a parameter and returns first unique letter in it (or return '?' if no unique letter is found).

Every single candidate is posed with this problem. It's not super trivial, but it doesn't require knowing anything past the absolute basics and some thinking. We do 5-10 interviews each week and we hired 3 people over past 4 months (and we need like 20 more). Most candidates fail on the above problem.


Programming is just a part of CS and is not taught in Uni much. I'd guess that it's because it takes practice and time is too restricted. But judging CS graduates on their programming skills is a poor indicator of their future performance, just like you wouldn't judge a doctor by how well he can stitch a wound.

On the other hand, lots of uni programs are just plain bad too.
Liquid`Jinro
Profile Blog Joined September 2002
Sweden33719 Posts
June 12 2017 04:01 GMT
#17762
On June 12 2017 06:58 TheEmulator wrote:
Show nested quote +
On June 12 2017 05:47 BrTarolg wrote:
I'm gonna do a 1 year masters, it seemed like a good idea and i don't mind learning some theoretical stuff, might be useful one day with a finance+maths background but who knows

What's cs50 edx?


CS50 is the intro to computer science course at Harvard, and it's offered as a MOOC (massive online open course) from Edx. The Edx version is called CS50x and it's basically an exact version of the actual course. The 2017 version has all the video lectures from 2016 and the same problem sets/syllabus. It's probably the most highly regarded MOOC alongside 6.00.1x from MIT. CS50 is so big at Harvard it's like a cult, lol. The prof is very entertaining tbh.

The MIT course is good too, but it's a bit harder and a lot more dry when it comes to the lectures. Also it has a schedule and some exams (it's a 2 month course), while CS50 can be completed any time during 2017.

edit: should note, CS50 is taught in C with a small module on python/html/css at the end. I think week 0 you have to use scratch for the problem set. 6.00.1x is all python.

I actually really loved the MIT professor (and grew to love the one in 6.00.2 as well), though you are right he's not as high energy as David Melan (I think that's his name?) for CS50.

What I personally liked about 6.00.1 as compared to CS50 is that they break the lecture up into like 10 short videos instead of a 1~2 hour long one, with questions and exercises in between. In terms of entertainment not as great but I liked the immediate reinforcement...
Moderatortell the guy that interplanatar interaction is pivotal to terrans variety of optionitudals in the pre-midgame preperatories as well as the protosstinal deterriggation of elite zergling strikes - Stimey n | Formerly FrozenArbiter
TheEmulator
Profile Blog Joined July 2010
28100 Posts
Last Edited: 2017-06-12 04:29:33
June 12 2017 04:25 GMT
#17763
On June 12 2017 13:01 Liquid`Jinro wrote:
Show nested quote +
On June 12 2017 06:58 TheEmulator wrote:
On June 12 2017 05:47 BrTarolg wrote:
I'm gonna do a 1 year masters, it seemed like a good idea and i don't mind learning some theoretical stuff, might be useful one day with a finance+maths background but who knows

What's cs50 edx?


CS50 is the intro to computer science course at Harvard, and it's offered as a MOOC (massive online open course) from Edx. The Edx version is called CS50x and it's basically an exact version of the actual course. The 2017 version has all the video lectures from 2016 and the same problem sets/syllabus. It's probably the most highly regarded MOOC alongside 6.00.1x from MIT. CS50 is so big at Harvard it's like a cult, lol. The prof is very entertaining tbh.

The MIT course is good too, but it's a bit harder and a lot more dry when it comes to the lectures. Also it has a schedule and some exams (it's a 2 month course), while CS50 can be completed any time during 2017.

edit: should note, CS50 is taught in C with a small module on python/html/css at the end. I think week 0 you have to use scratch for the problem set. 6.00.1x is all python.

I actually really loved the MIT professor (and grew to love the one in 6.00.2 as well), though you are right he's not as high energy as David Melan (I think that's his name?) for CS50.

What I personally liked about 6.00.1 as compared to CS50 is that they break the lecture up into like 10 short videos instead of a 1~2 hour long one, with questions and exercises in between. In terms of entertainment not as great but I liked the immediate reinforcement...

Definitely agree. The course is great and the prof is world class at what he does. I mostly meant he was dry compared to Malan, but I definitely feel engaged listening to him speak as well.

I loved the short videos with the 6.00.1x, although the long lectures in CS50 were tolerable because of Malan and seeing crowd interaction was pretty cool. You almost feel like you're in the class even though it was taped a year ago

edit: how is 6.00.2 btw? I haven't actually done that one yet. I'm assuming it's a direct continuation from the other course?
Administrator
Liquid`Jinro
Profile Blog Joined September 2002
Sweden33719 Posts
June 12 2017 05:44 GMT
#17764
6.00.2 starts off a loooot rougher than 6.00.1 and I don't purely mean this in a difficulty level sense. When I took it, there were a number of editing errors (video repeating the same info in different takes etc) in the first chapter.

However, I also realised that part of my initial feeling of discomfort was just because it was a tougher subject for me and after that I mostly loved the course. Overall, I'd say slightly less polished than 6.00.1 and the professor has a slightly different style (which I eventually grew fond of as well), but still very good.
Moderatortell the guy that interplanatar interaction is pivotal to terrans variety of optionitudals in the pre-midgame preperatories as well as the protosstinal deterriggation of elite zergling strikes - Stimey n | Formerly FrozenArbiter
dsyxelic
Profile Joined May 2010
United States1417 Posts
Last Edited: 2017-06-12 06:59:00
June 12 2017 06:25 GMT
#17765
I think my university curriculum puts more emphasis than most on practical programming

I learned basic web and mobile development through some classes (android, full-stack web app) which I figure isn't normal. was also taught things like version control, agile, etc. I was also told this normally wasn't the case but they added these things due to student feedback asking to teach these things in classes.

we also have a bunch of theoretical classes and math but I guess we can afford more classes due to it being a quarter school and requiring 5 years

i'm pretty thankful for this as I tend to enjoy the practical stuff more and school lights a fire under my ass for learning new things. but its also a PITA at times.

though i'm sure like most students i still have a shit ton to learn in the workforce. im realizing right now on my internship how underprepared i am for real work.

On June 12 2017 10:10 Manit0u wrote:
Show nested quote +
On June 12 2017 06:36 Fwmeh wrote:
On June 12 2017 03:12 Manit0u wrote:
On June 11 2017 22:24 BrTarolg wrote:
Hi!

I just completely learn python the hard way (except for the bits about creating web-pages)

And now im here haha. I wrote a blackjack simulator and tictactoe with some unit tests. Hoping to enter to do a masters in CS so i can do a career swap


I did career swap without any kind of degree in CS (all I have is bachelor's in Sociology and I've been following a successful programming career for the past 4 years with steadily increasing gains and positions). Just so you know, unless you're working with something that's very close to the "sciency" part of the CS you probably won't use 90% of what you learn there in a real work (especially not the way they teach you to program). I have a friend who has a PhD in CS (specializing in distributed systems and parallel computing), he switched from academic work to regular programming and his opinion is that he was living in the dark for all those years and even programmers just above junior position were better than him in the beginning.

There's plenty of people in my company (myself included) who'd love to get a degree in cognitivistics but unfortunately they don't offer weekend or evening classes so you can't really do that and work at the same time. Philosophy is actually super useful in programming since they teach you plenty of logic and abstractions in there.


I would actually strongly disagree. I would estimate that I have had use of roughly 80% of what I learned at university, either directly or indirectly. Looking back, I realize just how good our initial programming courses were.

That said, there were some very huge gaps, at least with the courses I took, most obviously:

1) How to work in larger, collaborative code-bases over a long period of time.

2) How to work effectively with requirements in a non-trivial business domain

3) How to manage legacy code/systems.

But the reason I would prefer to hire people with degrees over those without is simple that a degree is at least some hint (however imperfect) that I'm dealing with someone capable of learning. Hopefully fast, and hopefully reasonably sophisticated things. The most valuable thing (to me) in a potential hire would be a desire to always improve and learn new things.


It all depends on your uni (obviously, some have better courses than others). I just don't think it's a huge requirement or anything and way too many people think that if they get their CS degree they'll instantly become programmers (you wouldn't believe how many people apply for a job in my company only to learn they can't solve the most basic interview question). I even though about getting an engineer degree but when I solved some of the problems my friend needed help with (he was doing it at the time) I realized that it would just be a waste of every second weekend for the next 3 years just to get the paper. They give people some weird problems and after they get their degree they can't solve basically the only problem we give at interviews:

Write a function (any language, can be pseudocode, doesn't have to be optimal) that gets a string as a parameter and returns first unique letter in it (or return '?' if no unique letter is found).

Every single candidate is posed with this problem. It's not super trivial, but it doesn't require knowing anything past the absolute basics and some thinking. We do 5-10 interviews each week and we hired 3 people over past 4 months (and we need like 20 more). Most candidates fail on the above problem.


doesn't have to be optimal?
if so I'm pretty sure most students who finished their first year should be able to do it

def foo(s):
for i in xrange(0,len(s)):
if s[i] not in s[0:i] and s[i] not in s[i+1:len(s)]:
return s[i]
return "?"


not optimal at all (pretty sure dict would be the optimal choice?) but took me around a minute to think of a naiive solution and another minute or so to code it

well that gives me a confident boost especially cause I think I'm pretty average
TL/SKT
NovemberstOrm
Profile Blog Joined September 2011
Canada16217 Posts
June 12 2017 06:33 GMT
#17766
learning LINQ and lambda expressions so might be coming here for help
Moderatorlickypiddy
BrTarolg
Profile Blog Joined June 2009
United Kingdom3574 Posts
June 12 2017 14:16 GMT
#17767
On June 12 2017 10:10 Manit0u wrote:
Show nested quote +
On June 12 2017 06:36 Fwmeh wrote:
On June 12 2017 03:12 Manit0u wrote:
On June 11 2017 22:24 BrTarolg wrote:
Hi!

I just completely learn python the hard way (except for the bits about creating web-pages)

And now im here haha. I wrote a blackjack simulator and tictactoe with some unit tests. Hoping to enter to do a masters in CS so i can do a career swap


I did career swap without any kind of degree in CS (all I have is bachelor's in Sociology and I've been following a successful programming career for the past 4 years with steadily increasing gains and positions). Just so you know, unless you're working with something that's very close to the "sciency" part of the CS you probably won't use 90% of what you learn there in a real work (especially not the way they teach you to program). I have a friend who has a PhD in CS (specializing in distributed systems and parallel computing), he switched from academic work to regular programming and his opinion is that he was living in the dark for all those years and even programmers just above junior position were better than him in the beginning.

There's plenty of people in my company (myself included) who'd love to get a degree in cognitivistics but unfortunately they don't offer weekend or evening classes so you can't really do that and work at the same time. Philosophy is actually super useful in programming since they teach you plenty of logic and abstractions in there.


I would actually strongly disagree. I would estimate that I have had use of roughly 80% of what I learned at university, either directly or indirectly. Looking back, I realize just how good our initial programming courses were.

That said, there were some very huge gaps, at least with the courses I took, most obviously:

1) How to work in larger, collaborative code-bases over a long period of time.

2) How to work effectively with requirements in a non-trivial business domain

3) How to manage legacy code/systems.

But the reason I would prefer to hire people with degrees over those without is simple that a degree is at least some hint (however imperfect) that I'm dealing with someone capable of learning. Hopefully fast, and hopefully reasonably sophisticated things. The most valuable thing (to me) in a potential hire would be a desire to always improve and learn new things.


It all depends on your uni (obviously, some have better courses than others). I just don't think it's a huge requirement or anything and way too many people think that if they get their CS degree they'll instantly become programmers (you wouldn't believe how many people apply for a job in my company only to learn they can't solve the most basic interview question). I even though about getting an engineer degree but when I solved some of the problems my friend needed help with (he was doing it at the time) I realized that it would just be a waste of every second weekend for the next 3 years just to get the paper. They give people some weird problems and after they get their degree they can't solve basically the only problem we give at interviews:

Write a function (any language, can be pseudocode, doesn't have to be optimal) that gets a string as a parameter and returns first unique letter in it (or return '?' if no unique letter is found).

Every single candidate is posed with this problem. It's not super trivial, but it doesn't require knowing anything past the absolute basics and some thinking. We do 5-10 interviews each week and we hired 3 people over past 4 months (and we need like 20 more). Most candidates fail on the above problem.


let me have a crack at this in pseudocode lmao

function getunique(x):

x = rawinput
a = x.split // returns a list/array of individual strings
value = "?"

for b in range(len(a))
for c in range(len(a))
if a[b] == a[c] and c != b
value = c

return value


Something like that? haha
noob programmer here
tofucake
Profile Blog Joined October 2009
Hyrule19228 Posts
June 12 2017 14:26 GMT
#17768
it's pretty trivial in php too:

function first_unique_letter($param) {
$a = explode('', $param);
$b = array_unique($a);
return reset($b) ?: '?';
}
Liquipediaasante sana squash banana
phar
Profile Joined August 2011
United States1080 Posts
Last Edited: 2017-06-12 17:42:36
June 12 2017 17:38 GMT
#17769
You can do in o(n) time and o(n) space instead of o(n^2) time, but that will only matter if you have prodigiously large strings. That would be a reasonable tradeoff I'd look for as an interviewer (have done ~100 interviews, probably majority of those are undergrad/masters candidates). But that sort of question wouldn't generate much interesting code, so I'd slot that for an easy warmup and expect the candidate to bang it out with functioning code (not pseudo) in like 5 min, before moving on to other shit.



But yea I'd echo what others have been saying RE Uni programming skills. Don't expect much, and employers aren't expecting much either. I've only worked with a couple of new grads who actually wrote good code (and I wouldn't include myself in that group, back when I was a new grad...). University code/programming is by and large complete crap.
There's definitely variance between Universities, but the bar is pretty low. Some problems common problems you'll see with a Uni grad's code:
  • Tries to be too clever
  • Code is horribly nested, or otherwise hard to follow
  • Unit testing? Ha no, we just got it to compile.
  • System/integration testing? Might not even know what this is...
  • Code has essentially no sense of API design (vs something thought out)

etc etc

A lot of this comes from the fact that Uni code/programming and actual real-world code/programming has some major differences:
  • Real world code generally serves some ongoing purpose or solution, and evolves gradually, and thus needs to be maintained in a very different fashion. Uni code is more often one-shot. Or, if you're very unlucky, you get to inherit some ball of legacy mess from previous grad students and try to Frankenstein stuff on top for your paper, at which point you hand it off to the next poor sap. Of course, there's a good bit of Frankensteining crap code on top in industry too.
  • Industry code is more often than not going to make prodigious use of existing libraries and institutional knowledge, rather than trying to reinvent the wheel. In Uni, often the whole point of the assignment is to reinvent the wheel.
  • If a mistake is made in pushing industry code to production, you may start hemorrhaging thousands of dollars per minute, if it's a billion dollar product. There isn't "production" for Uni code, but if a mistake is made there, you may get knocked down half a letter grade or something. So stakes are very different.
  • Industry code / programming is going to end up involving a lot more pieces than Uni code - actually the code bit of industry is only a small part. Docs, configs, productionization, testing, and rampant political bullshit will take up more of your time.
  • Real world code is typically read an order of magnitude more times than it is written, and by people who might not even know the person who wrote it, and spaced out by a period of N years (5, 10, or more). (By "read", I mean humans looking at the code trying to figure out / verify what it does). Uni code is typically written and re-written frantically and then read exactly 0 or 1 times (either as part of a course, or in the PhD paper mill crunch happy fun time factory)
  • On that note, actually I've seen a lot of PhD candidates who can't code their way out of a cardboard box, because PhD research quality code is a whole different ballgame
Who after all is today speaking about the destruction of the Armenians?
Blitzkrieg0
Profile Blog Joined August 2010
United States13132 Posts
June 12 2017 17:47 GMT
#17770
On June 12 2017 12:02 TheEmulator wrote:
I'm so scared to start applying before I feel really confident that my base skills are where I believe they need to be. I can't understand how people who are clueless go around applying for jobs. Do they not know they are clueless, or are they hoping someone takes a chance on them or doesn't notice


If you've never programmed in front of a human being before and explained your thought process I suggest getting some friends together and practicing. The whole interview process where you're coding and explaining what you're doing is pretty overwhelming if you've never done it before.
I'll always be your shadow and veil your eyes from states of ain soph aur.
dsyxelic
Profile Joined May 2010
United States1417 Posts
June 12 2017 17:49 GMT
#17771
Would you be willing to share a good interview question that helps you assess a candidate the best over others? Im curious as I havent been on a real technical interview yet (white boarding and such). I have a general idea for big n's and such but not your average company (excuse me if you work at one of the aforementioned type of companies)
TL/SKT
beg
Profile Blog Joined May 2010
991 Posts
Last Edited: 2017-06-12 19:08:54
June 12 2017 18:43 GMT
#17772
And a solution using regex in Python!

def unique(word):
for char in word:
if len(re.findall(char,word)) == 1:
return char
return '?'
Manit0u
Profile Blog Joined August 2004
Poland17789 Posts
Last Edited: 2017-06-12 19:26:19
June 12 2017 19:24 GMT
#17773
On June 12 2017 23:26 tofucake wrote:
it's pretty trivial in php too:

function first_unique_letter($param) {
$a = explode('', $param);
$b = array_unique($a);
return reset($b) ?: '?';
}


Oh, really?


function first_unique_letter($param) {
$a = explode('', $param);
$b = array_unique($a);
return reset($b) ?: '?';
}

echo first_unique_letter("tesseract");

E_WARNING : type 2 -- explode(): Empty delimiter -- at line 4

E_WARNING : type 2 -- array_unique() expects parameter 1 to be array, boolean given -- at line 5

E_WARNING : type 2 -- reset() expects parameter 1 to be array, null given -- at line 6

?

// fixed code that actually runs
function first_unique_letter($param) {
$a = str_split($param);
$b = array_unique($a);
return reset($b) ?: '?';
}

echo first_unique_letter("tesseract");

t


Array unique will turn "tesseract" into "tesrac" and then you simply return the first element.

It's actually way harder to do than you imagine in PHP since it's array and string operators are pretty shit (I have yet to meet a person who remembers all of the array and string function param orders). I came from PHP, interviewing for Ruby and I've actually tackled this problem with C (with which I have next to no experience).
Time is precious. Waste it wisely.
Nesserev
Profile Blog Joined January 2011
Belgium2760 Posts
Last Edited: 2017-06-12 19:51:41
June 12 2017 19:30 GMT
#17774
--- Nuked ---
Poopi
Profile Blog Joined November 2010
France13003 Posts
June 12 2017 19:34 GMT
#17775
Hi, I'd like to improve my technical skills in Python during the summer since I feel I waste some time in machine learning classes when we implement stuff using Python.

I looked at the Python guides from the old OP but some of them (google one for example) are for absolute beginners in Python.
I already know a bit about it since I used it relatively frequently for 1.5 years now, so I am not an absolute beginner, but I'm not good enough to properly evaluate where I'm lacking and pick a guide accordingly.

So should I go with the google one for beginners in order not to miss a thing, even though there'll be things I already know, or seek another guide but not being sure I got all the basics?
WriterMaru
beg
Profile Blog Joined May 2010
991 Posts
June 12 2017 19:39 GMT
#17776
On June 12 2017 23:16 BrTarolg wrote:
Show nested quote +
On June 12 2017 10:10 Manit0u wrote:
On June 12 2017 06:36 Fwmeh wrote:
On June 12 2017 03:12 Manit0u wrote:
On June 11 2017 22:24 BrTarolg wrote:
Hi!

I just completely learn python the hard way (except for the bits about creating web-pages)

And now im here haha. I wrote a blackjack simulator and tictactoe with some unit tests. Hoping to enter to do a masters in CS so i can do a career swap


I did career swap without any kind of degree in CS (all I have is bachelor's in Sociology and I've been following a successful programming career for the past 4 years with steadily increasing gains and positions). Just so you know, unless you're working with something that's very close to the "sciency" part of the CS you probably won't use 90% of what you learn there in a real work (especially not the way they teach you to program). I have a friend who has a PhD in CS (specializing in distributed systems and parallel computing), he switched from academic work to regular programming and his opinion is that he was living in the dark for all those years and even programmers just above junior position were better than him in the beginning.

There's plenty of people in my company (myself included) who'd love to get a degree in cognitivistics but unfortunately they don't offer weekend or evening classes so you can't really do that and work at the same time. Philosophy is actually super useful in programming since they teach you plenty of logic and abstractions in there.


I would actually strongly disagree. I would estimate that I have had use of roughly 80% of what I learned at university, either directly or indirectly. Looking back, I realize just how good our initial programming courses were.

That said, there were some very huge gaps, at least with the courses I took, most obviously:

1) How to work in larger, collaborative code-bases over a long period of time.

2) How to work effectively with requirements in a non-trivial business domain

3) How to manage legacy code/systems.

But the reason I would prefer to hire people with degrees over those without is simple that a degree is at least some hint (however imperfect) that I'm dealing with someone capable of learning. Hopefully fast, and hopefully reasonably sophisticated things. The most valuable thing (to me) in a potential hire would be a desire to always improve and learn new things.


It all depends on your uni (obviously, some have better courses than others). I just don't think it's a huge requirement or anything and way too many people think that if they get their CS degree they'll instantly become programmers (you wouldn't believe how many people apply for a job in my company only to learn they can't solve the most basic interview question). I even though about getting an engineer degree but when I solved some of the problems my friend needed help with (he was doing it at the time) I realized that it would just be a waste of every second weekend for the next 3 years just to get the paper. They give people some weird problems and after they get their degree they can't solve basically the only problem we give at interviews:

Write a function (any language, can be pseudocode, doesn't have to be optimal) that gets a string as a parameter and returns first unique letter in it (or return '?' if no unique letter is found).

Every single candidate is posed with this problem. It's not super trivial, but it doesn't require knowing anything past the absolute basics and some thinking. We do 5-10 interviews each week and we hired 3 people over past 4 months (and we need like 20 more). Most candidates fail on the above problem.


let me have a crack at this in pseudocode lmao

function getunique(x):

x = rawinput
a = x.split // returns a list/array of individual strings
value = "?"

for b in range(len(a))
for c in range(len(a))
if a[b] == a[c] and c != b
value = c

return value


Something like that? haha
noob programmer here

your code is returning the index of a non-unique letter. but we want to return the first unique letter.
Nesserev
Profile Blog Joined January 2011
Belgium2760 Posts
Last Edited: 2017-06-12 20:06:55
June 12 2017 19:59 GMT
#17777
--- Nuked ---
Acrofales
Profile Joined August 2010
Spain18371 Posts
June 12 2017 20:22 GMT
#17778
On June 13 2017 04:30 Nesserev wrote:
Show nested quote +
On June 13 2017 04:24 Manit0u wrote:
+ Show Spoiler +
On June 12 2017 23:26 tofucake wrote:
it's pretty trivial in php too:

function first_unique_letter($param) {
$a = explode('', $param);
$b = array_unique($a);
return reset($b) ?: '?';
}


Oh, really?


function first_unique_letter($param) {
$a = explode('', $param);
$b = array_unique($a);
return reset($b) ?: '?';
}

echo first_unique_letter("tesseract");

E_WARNING : type 2 -- explode(): Empty delimiter -- at line 4

E_WARNING : type 2 -- array_unique() expects parameter 1 to be array, boolean given -- at line 5

E_WARNING : type 2 -- reset() expects parameter 1 to be array, null given -- at line 6

?

// fixed code that actually runs
function first_unique_letter($param) {
$a = str_split($param);
$b = array_unique($a);
return reset($b) ?: '?';
}

echo first_unique_letter("tesseract");

t


Array unique will turn "tesseract" into "tesrac" and then you simply return the first element.

It's actually way harder to do than you imagine in PHP since it's array and string operators are pretty shit (I have yet to meet a person who remembers all of the array and string function param orders). I came from PHP, interviewing for Ruby and I've actually tackled this problem with C (with which I have next to no experience).

You're actually supposed to return the first letter that's unique in the original string. Now you just return the first letter The letter 'r' is supposed to be the first unique letter.

Show nested quote +
On June 13 2017 02:49 dsyxelic wrote:
Would you be willing to share a good interview question that helps you assess a candidate the best over others? Im curious as I havent been on a real technical interview yet (white boarding and such). I have a general idea for big n's and such but not your average company (excuse me if you work at one of the aforementioned type of companies)

Here's a good one.

You're the new guy on the team. A client calls you with a panicked voice, and tells you shit is going sideways REALLY BAD. You log in to the system and see a bunch of error messages that you don't know anything about, BUT your boss and co-workers are all out of office and can't be reached, because they all went to celebrate Jeff's birthday (you weren't invited, because they don't want you to know about their secretive cocaine and hooker parties until they can trust you).

What's the first thing you do?


Tell the client that everything is completely normal in your end, and find some cocaine and hookers. Then act all surprised the next day when your colleagues realize the system has been down for however many hours.
Deleted User 3420
Profile Blog Joined May 2003
24492 Posts
June 12 2017 20:40 GMT
#17779
Boolean logic stuff:

http://www.cs.umd.edu/class/summer2017/cmsc351/hwk-np.pdf

I don't understand 5a onward AT ALL. Can someone point me in the right direction?

The only thing I can come up with is just to directly convert the formulas into circuits. Then for 5b I just drew the circuit. Then for 6a the answer would be that it is big theta n... because the circuit is a 1 to 1 representation.

I am clearly not understanding something here...
Poopi
Profile Blog Joined November 2010
France13003 Posts
Last Edited: 2017-06-12 20:57:58
June 12 2017 20:57 GMT
#17780
A Boolean formula is satisfiable if and only if there exists an interpretation of your variables (for example, x OR y is satisfiable because there exists an interpretation of x, y that makes the formula true, ie. x=1 and y=0) that makes the formula true.

@Nesserev: thanks I'll try that
WriterMaru
Prev 1 887 888 889 890 891 1032 Next
Please log in or register to reply.
Live Events Refresh
Next event in 10h 10m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
ZombieGrub172
SpeCial 106
StarCraft: Brood War
ZZZero.O 39
Counter-Strike
summit1g7625
Other Games
tarik_tv4623
Grubby2824
Liquid`RaSZi1603
fl0m587
shahzam555
C9.Mang0327
ToD235
XaKoH 162
Organizations
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
[ Show 14 non-featured ]
StarCraft 2
• RyuSc2 34
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• TFBlade877
Other Games
• imaqtpie879
• Shiphtur305
Upcoming Events
Replay Cast
10h 10m
CrankTV Team League
12h 10m
Replay Cast
1d 10h
CrankTV Team League
1d 12h
Replay Cast
2 days
RSL Revival
2 days
Clem vs Lambo
Scarlett vs Cure
CranKy Ducklings
2 days
IPSL
2 days
Dragon vs Hawk
RSL Revival
3 days
Classic vs Trap
herO vs SHIN
Sparkling Tuna Cup
3 days
[ Show More ]
IPSL
3 days
Bonyth vs Ret
WardiTV Weekly
4 days
Monday Night Weeklies
4 days
PiGosaur Cup
6 days
The PondCast
6 days
Liquipedia Results

Completed

YSL S3
HSC XXIX
Eternal Conflict S2 E2

Ongoing

IPSL Spring 2026
Acropolis #4
CSL 2026 Summer (S21)
KCM Race Survival 2026 Season 3
RSL Revival: Season 6
CranK Gathers Season 4: BW vs SC2 Team League
SCTL 2026 Spring
Stake Ranked Episode 3
XSE Pro League 2026
IEM Cologne Major 2026
Stake Ranked Episode 2
CS Asia Championships 2026
Asian Champions League 2026
IEM Atlanta 2026
PGL Astana 2026
BLAST Rivals Spring 2026

Upcoming

Escore Tournament S3: W3
ASL S22 SEASON OPEN Day 1
Escore Tournament S3: W4
ASL S22 SEASON OPEN Day 2
Escore Tournament S3: W5
CSLAN 4
Blizzard Classic Cup 2026
HSC XXX
SC4ALL II: StarCraft II
Kung Fu Cup 2026 Grand Finals
Light Tournament 2026
Eternal Conflict S2 Finale
Eternal Conflict S2 E3
Logitech G Connect 2026
StarSeries Fall 2026
FISSURE Playground #5
BLAST Open Fall 2026
Esports World Cup 2026
BLAST Bounty Summer 2026
BLAST Bounty Summer Qual
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2026 TLnet. All Rights Reserved.