Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
GameCube
Nov 21, 2006

gonna write a :cool: compiler for this class
the language itself is pretty bad but that's because it's written to be easy to write a compiler for, not to actually use

quote:

For instance, the language supports less than comparisons but not greater than.

Adbot
ADBOT LOVES YOU

GameCube
Nov 21, 2006

Anal Tributary posted:

code:
i<string.length-1
welp have fun working at best buy again

GameCube
Nov 21, 2006

i liked objective c in school but i feel like i wouldn't have understood it as well if i didn't already know c

GameCube
Nov 21, 2006

all that talk about two degrees vs. no degrees reminds me of this one supervisor i had when i worked a lovely computer lab job in college. spent 6 years in school his first time around because he started out in comp. eng. and couldn't hack it, switched to a dual major in japanese and east asian studies because anime. graduated, worked a call center job for a year, took two years off for "mental health," then came back to get another bachelor's in IST. what a winner

GameCube
Nov 21, 2006

ahhh spiders posted:

lmao at getting a degree in japanese because you like anime

not just one, but two. he also wore a bucket hat all day every day

GameCube
Nov 21, 2006

re: programming languages

so i'm taking that online compilers class and during yesterday's lecture he showed three examples of archaic programming languages with ambiguity that can gently caress with lexical analysis

fortran, pl/1

guess the third one

GameCube
Nov 21, 2006

the answer is c++

and it's kinda cool so far but they're not real far into it yet. first actual assignments were posted yesterday so if you want in now's the time

GameCube
Nov 21, 2006

ahhh spiders posted:

what's the ambiguity in C++?

ambiguity's probably the wrong word for it (this is why i'm taking the class, i want to ~learn~) but the example he used was that for a long time compilers saw the closing >s in a nested template declaration (e.g. list<vector<int>>) as the stream operator and you had to put whitespace in there to make it work

GameCube
Nov 21, 2006

https://www.coursera.org/course/compilers if anybody else is interested

GameCube
Nov 21, 2006

ahhh spiders posted:

don't they still do that

he said most compilers had fixed it by now, i didn't try it myself

GameCube
Nov 21, 2006

ahhh spiders posted:

it actually knows what the problem is, though

error: `>>' should be `> >' within a nested template argument list

having trouble understanding why this would possibly be the correct behavior unless there was a valid way of using the stream operator within a nested template argument list, apart from spergy "when in doubt, fail" attitudes

GameCube
Nov 21, 2006

ahhh spiders posted:

there is

A<int, 1024>>2> a;

ohshit

GameCube
Nov 21, 2006

ahhh spiders posted:

kind of contrived, sure, but it exists

but wait, there's no opening < to match those >s, couldn't the lexer still figure it out

JawnV6 posted:

hm, im off track and might not have a goddamn clue what context im in, BETTER CHAREG AHEAD"
well in this case the error message would suggest that it knows exactly what context it's in and it's failing anyway just to spite the programmer? idk but somebody post that thing about jawns v1-5

GameCube
Nov 21, 2006

so if i'm understanding correctly, it's not that it's impossible to parse, just that it's a pain in the rear end

maybe they shouldn't have made ">>" mean 3 (at least?) different things in the first place?

GameCube
Nov 21, 2006

Janin posted:

Nested templates vs the bitshift operator are symptomatic of C++'s poor design, but they're not a fundamental issue with the language so much as just a minor mistake in the grammar. Every major compiler will provide a decent error message in C++98 mode, and should accept it in C++11 mode.

"Ambiguity" is the wrong word, his professor was probably generalizing a bit.

The problem with C++ is that is grammar is undecidable and its template system is Turing-complete. Together, this means that it is literally impossible to create a C++ parser. The only way to process C++ is to compile it.

Perl 5 (and probably 6) has a similar issue.

yeah that was my bad, using words without regard for their actual definition

anyway thanks for enlightening me y'all, time to go learn flex apparently

GameCube
Nov 21, 2006

speaking of forth if any of y'all are arduino nerds, the gameduino coprocessor is the guy's custom forth cpu. was thinking of picking one of these up a while back but got distracted by something shiny

GameCube
Nov 21, 2006

ppp posted:

use a msp430

GameCube
Nov 21, 2006

nobody in yospos is dumb enough that they can't use a real microcontroller instead of some lovely dev board loaded up with unnecessary poo poo that sucks power and leaves you with no room for your code. I only posted that gameduino poo poo because an accessible forth cpu seemed neat

GameCube
Nov 21, 2006

ppp posted:

a msp430 is like five dollars and im pretty sure i read something that they made a newer revision of it and now its the most energy efficient microcontroller or something.

$4.30 for a kit that comes with two chips, a target board and a usb cable

and yeah the low power modes are their big selling point, it uses something on the scale of microamps in some cases

GameCube
Nov 21, 2006

Otto Skorzeny posted:

sleep modes on the order of uamps aren't really a new thing wrt ucs

oh ok. it was my first time actually looking at current consumption so idfk

GameCube
Nov 21, 2006

since the php thread got closed somebody who isn't dumb explain this to me http://ompldr.org/vZGxxaQ
apparently it's a mirror because the original got marked private

GameCube
Nov 21, 2006

i'm never going to forget the :psyduck: attempt at an algorithms question i got in my last interview. maybe one of you can make some sense of what the gently caress he was trying to get at:

him: "so, you have a circular linked list, you don't know where it starts or ends, and you want to know when you've visited every element. but you can't save anything!"

me: "..."

him: "but i'll give you a hint: you have two pointers"

me: "uh, leave one pointer at the first element you have, traverse the list with the other, and when the two pointers are equal again, you've been through the whole list"

him: "no no no, you can't save anything! all you have are these two pointers!"

that went back and forth for about ten minutes before i gave up and said i must not understand the question, chalked it up to his broken english. at the end of the interview when he asked if i had any questions for him, i said yeah, what the gently caress answer were you looking for there

and he gets this sly grin on his face and explains that every time you move one pointer ahead by one node, you move the other pointer ahead TWO nodes, and when the pointers equal each other, you've been through the whole list.

the punchline is that this man is now my boss

GameCube
Nov 21, 2006

MononcQc posted:

Tortoise and hare is the algorithm he wanted you to mention.

this makes perfect sense because, knowing him, he probably flipped open that algorithms textbook that's sitting on his desk (you all know the one) to a random page and spent five seconds trying to memorize it before i came in for the interview. reading comprehension is not his strong suit

GameCube
Nov 21, 2006

pay's good, benefits are good, and i don't do poo poo
so, yeah

GameCube
Nov 21, 2006

now that i think about it, i think he even started out asking the question correctly, then changed his mind mid-question and made it a circular linked list instead to make it "easier." but then when i gave him an answer that worked for the simpler case, he couldn't comprehend the possibility that it was correct because it wasn't the one he was thinking of

this pattern has repeated itself many times since then

GameCube
Nov 21, 2006

Anal Tributary posted:

this thread in one tab, about eight different wikipedia articles in others

man. algorithms and data structures and poo poo. gotta get a book. self-teach it. maybe one of those colleges that does the open free online course stuff will have an algos one?

one just ended but i think the material's still up https://class.coursera.org/algo/class/index
e: and he's re-running it in a month or so

GameCube
Nov 21, 2006

ahhh spiders posted:

are you trying to get a job in the industry because if they don't see a degree and you don't have experience it's probably not going to happen

pretty sure he's in school and just needs an internship but he thinks if he doesn't have 5+ years of professional experience nobody's going to give him one

GameCube
Nov 21, 2006

Anal Tributary posted:

i really like this because it has the exams and stuff, so maybe i could use it with a book or lectures or something. the lecture notes don't really seem like they give a complete picture.

the difference between coursera and the mit opencourseware-type stuff is that coursera's material is original for the coursera course. like, the lecture videos aren't just some guy with a camcorder videotaping the normal lecture, they're a narrated whiteboard recording kinda thing. plus if you're the kind of person who needs some structure it's kinda cool that there's assignments with due dates.

actually if you want in on a class that's actually running now, this one just started and is more theoretical and poo poo like an algorithms course: https://www.coursera.org/course/automata

GameCube
Nov 21, 2006

you're in school, you don't need experience to do an internship. that's the whole point of internships, to teach you the poo poo you actually need to know in order to work a real job

GameCube
Nov 21, 2006

Rufo posted:

WHAT A GRAPH IS

a bad poster

GameCube
Nov 21, 2006

Rufo posted:

CLRS is an obvious book suggestion for data structures and algorithms idk what the ~goon opinion~ of it is but its probably on like 99% of university reading lists

fyi this is the book i was referring to

GameCube
Nov 21, 2006

jooky posted:

you should be more confident in your abilities b/c your desire to learn combined w/ your current knowledge is much better than most students (especially freshman) so you are a really good candidate for most internships. just look for them and apply instead of selling yourself short by getting a dumb retail job.

yup this. and don't avoid interviews just because you don't think you're qualified. my best internship came from a guy who openly talked poo poo on my resume when i gave it to him at the career fair ("don't bother with that 'major gpa' poo poo, we all know what that means"), and when it was time to graduate i interviewed at a few places i wasn't interested in just for the experience. by the time i interviewed for job i was actually qualified for and wanted to get, there was no stress at all

GameCube
Nov 21, 2006

ahhh spiders posted:

do people in jobs really have a 200 level cmpt textbook on their desk?

this guy does. idfk why

GameCube
Nov 21, 2006

trex eaterofcadrs posted:

a bunch of the stuff in cormen is above 200 level unless you're like mr cmu i do nothing else but computer poo poo

i don't think the level is important so much as the book actually being relevant to the job (it isn't)

GameCube
Nov 21, 2006

Nomnom Cookie posted:

ur old I didn't know that!! :wth: i only meant your wrong but if yo uare old too than that makes a lot of cents!!!

your posting is always pretty poo poo but this one in particular was offensively bad. please leave and never return.

GameCube
Nov 21, 2006

so i guess this is the thread for this. got a fun text from my dad, who wrote visual basic for three years in the 90s:

quote:

If I wanted to write my own simple web browser, what would be the best language to learn?
didn't know where to being with that one
half an hour later while i'm still trying to wrap my brain around that, i get another

quote:

Ok looks like the answer is c++ according to what I found online...

GameCube
Nov 21, 2006

just a butt posted:

verilog

ASICs for everything. i can get behind this

GameCube
Nov 21, 2006

yaoi prophet posted:

sorry but being able to commit and then go 'oh gently caress i made a typo in this comment' and fixing it up with commit --amend (or rebase if i've made commits in between) owns

at my last job you could edit svn commit logs after the fact. at my current one we can't, but they also apparently had just switched from visual sourcesafe like a year before i got here

e: here u go http://subversion.apache.org/faq.html#change-log-msg

GameCube
Nov 21, 2006

also please get a new avatar already, why do you still have that anime poo poo

Adbot
ADBOT LOVES YOU

GameCube
Nov 21, 2006

yaoi prophet posted:

lol if you don't browse with avatars off for Maximum Posting Bandwidth

i actually do since i do most of my yosposting from work but just knowing that an animetar is posting in yospos still irks me

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply