Writing a report about Computer Science for school, looking for information



  • @Vaire said:

    As can network programming in C++ (hi, it is the 21st century, nobody does this any more with C++).

    So what's your language of choice for writing a physics-heavy MMO server?



  • @xaade said:

    Ok?

    What's your definition of discrete math?

    That class where you prove that sqrt(2) is irrational and half the students decide to switch majors.


  • Winner of the 2016 Presidential Election

    @Groaner said:

    During my brief stint as a CS major, we were all instructed to do our work ssh'd into a Solaris cluster using GCC and actively discouraged from using any modern IDE.

    :facepalm:

    Ok, compiling & debugging on a remote system may sometimes be necessary, but there's still SSHFS so you can at least use a freaking IDE when writing the code!


  • Winner of the 2016 Presidential Election

    @Groaner said:

    That class where you prove that sqrt(2) is irrational

    That was in high school (at least in my case).


  • Banned

    @asdf said:

    Hm, not necessarily. If you base your mental model on the data you're processing and what kind of operations you're performing on it instead of the other way around, you're already Doing It Right.

    You misunderstood me. Doing It Right™ almost always takes more time than Doing It Okay™, and a programmer who is capable of Doing It Right™ are more expensive to hire. If every software was done like you would like it to, the development would be necessarily more costly.

    Of course, even more costly is Doing It Wrong™, which is not just suboptimal performance, but also unmaintainable mess which needs much more effort to fix than if it was done right from the beginning. Frankly, this is very common in software development - and this is where my theory goes to hell.

    @asdf said:

    On a low level (method implementation), yes. On a high level (design error), no.

    If it looks okay at low level, then it looks okay at high level too. Of course, if more effort were spent on design (I'd say way, way, way more effort), then in a typical application, everything could run about 4-10x faster. The thing is, nobody cares.

    @asdf said:

    Oh, and have I ever mentioned how much I hate that most CS courses sell recursion as a great concept, when it's something that you should never, ever use in real code if you can avoid it?

    There are some algorithms where recursive approach is orders of magnitude easier than iterative. Say, parsing.

    @Groaner said:

    During my brief stint as a CS major, we were all instructed to do our work ssh'd into a Solaris cluster using GCC and actively discouraged from using any modern IDE. I have become convinced that the goal of many undergraduate departments is not to give students job skills and prepare them for the real world, but to prepare those same students for grad school.

    Fun fact: my current job requires me to ssh into build server if I want to build anything. Also, no IDE can parse our project correctly, so they're mostly useless. My current setup is some cheap text editor (slightly more advanced than Windows's Notepad) and self-made wrapper for make that uses rsync and ssh.

    Personally, I'd argue working without IDE is more useful knowledge than how to implement hashmap.



  • I had no idea there'd be this many replies.

    I feel as if I may have missed a few notes in the program grid; The Gantt Chart/critical path is introduced in Intro to CS and reexplained in Systems Development, JUnit Tests are done in Programming 2, and there's a brief explanation of how to/how not to make your UI for Systems Development (arngren.net being a perfect example of how NOT to make your website).

    I also accidentally forgot the dot in NET programming. It's supposed to be .NET, as in the Microsoft framework. Given how I confused some people here/myself, I'd likely put in the report that it should be called Intro to C++, as that's what it essentially is. No networking, mostly just doing examples out of the textbook.



  • .NET & C++ are a very weird combination. It's definitely possible to simultaneously use both, but it's very very very rare to actually see it "in the wild" so to speak. It's kind of an aborted technology Microsoft gave up on back in like 2003...

    There are very few languages LESS suited to work with the .NET framework than C++.

    Personally, I hate the idea of even teaching students C++. If you need low-level, stick with C. If you wanna be enterprising, pick D or Rust. Even Go would be better. I would hope most engineers agree at this point that C++ is a bad idea.


  • Winner of the 2016 Presidential Election

    @blakeyrat said:

    I would hope most engineers agree at this point that C++ is a bad idea.

    Have you ever seen "modern" C++14 code? The language has improved a lot and if you actually use the new features, it's easy to write exception-safe and leak-free programs now that are actually readable.

    Rust may still be a better choice for new projects, but I wouldn't say starting a new C++ project is a "bad idea" anymore. Now we just have to make sure all those tutorials teaching people C++98 vanish so people don't get taught the "wrong" stuff. (Yeah, never gonna happen.)


  • Winner of the 2016 Presidential Election

    @joshtheskilledgamer said:

    Intro to C++

    Some additional feedback: Make sure this class teaches C++11, not "old" C++. (Above all, teach them to always use unique_ptr or shared_ptr instead of raw pointers.) Teaching people C++98 these days is a really, really bad idea.



  • @asdf said:

    Have you ever seen "modern" C++14 code?

    Doesn't matter. C++ isn't a bad language because it doesn't have enough "new stuff", it's a bad language because it's never removed the "old stuff" that was all bad ideas.

    I'm sure it's possible to write good clean nice C++14 code, but that doesn't mean that when you hand the project off to Bob he'll keep it good clean and nice. Or that Bob even learned the good clean nice variant of the language.

    You admit yourself:

    @asdf said:

    Now we just have to make sure all those tutorials teaching people C++98 vanish so people don't get taught the "wrong" stuff. (Yeah, never gonna happen.)

    Does that seem like a good language to use for beginning programmers? A language where you know the vast majority of reference and help material is bad?


  • Winner of the 2016 Presidential Election

    @blakeyrat said:

    C++ isn't a bad language because it doesn't have enough "new stuff"

    Actually, the new stuff that is going to be standardized with C++17 is pretty exciting.

    @blakeyrat said:

    never removed the "old stuff" that was all bad ideas

    At least there is an official style guide in development that is going to be supported by compilers in the future (emit warnings when you're using stuff you shouldn't use). Not an ideal solution, but they're not totally ignoring the problem.

    @blakeyrat said:

    Or that Bob even learned the good clean nice variant of the language.

    That's exactly why it might be a good idea to educate college students. To make sure they know what "good" C++ code is supposed to look like when they encounter a C++ project somewhere (and many will).

    @blakeyrat said:

    Does that seem like a good language to use for beginning programmers?

    Hell no. Definitely not something you should teach during the first two years.



  • @asdf said:

    At least there is an official style guide in development that is going to be supported by compilers in the future (emit warnings when you're using stuff you shouldn't use). Not an ideal solution, but they're not totally ignoring the problem.

    I understood, at a certain point, where there was a desire to make C++ backwards compatible with C.

    But that's no longer the case.

    If someone wants to use the newer compiler, they need to write the correct code.



  • I feel that data structures are absolutely necessary for line-of-business programmers to be familiar with, for the simple fact that often, your business' data will be organized in one of those structures. Like, when I was importing someone's cost centers, where their organizational structure is a graph, into our system which can only store it as a tree, I had to transform that shit. And guess what: after learning about red-black, and self balancing trees, and all that other shit that I've already forgotten, it was a piece of piss, but before I actually learned all that, this kind of thing would have done my head in.

    I think a good course might be “data structures and ui design”, as in, take some data that is structured a certain way, and show it to the user. I'm picturing it as a very theory-heavy course, maybe along the lines of Blakey's history of computing idea, where you just show them different data structures and ways that people have presented such data in the past. Try to get them familiar with the idea that every problem they are going to encounter has been solved before. Because I haven't been programming for long, but the number of times I've seen people pulling their hair out over some basic data structure, making up vocabulary to try to describe it insted of just calling it by name, well, it's more than one time, and even one time is way too many imo.

    Final project: get them to build a better ui for git :trollface:



  • @blakeyrat said:

    There are very few languages LESS suited to work with the .NET framework than C++.

    I used c++/CLI once to make a 'glue' code between a c++ library and a c# application. It was much simpler than trying to make that work with pinvokes, because c++/CLI can use a c++ library directly, and implement a managed .net class.


  • Java Dev

    True, but if you're writing a language A program and need to use a language B library you'll almost always need to write code on both sides because a smaller interface leads to less code.

    I once had to call a java library from a C program, ended up writing a 30-line java helper class to save me about 200 lines of C code.



  • @fbmac said:

    I used c++/CLI once to make a 'glue' code between a c++ library and a c# application. It was much simpler than trying to make that work with pinvokes, because c++/CLI can use a c++ library directly, and implement a managed .net class.

    This. I've had to do something similar to interop with DirectShow and obscure C image libraries.



  • @Buddy said:

    I feel that data structures are absolutely necessary for line-of-business programmers to be familiar with

    Quite. Data structures also fall naturally into a real CS degree program as opposed to the "IT Skills" crap detailed in the OP.


  • Considered Harmful

    @xaade said:

    Math proofs are invaluable in developing the type of mind that thinks in TDD.

    Prove it works for value 1, prove it works for value n, prove it works for value n+1.

    Invaluable for unit testing design.


    I'd like to see a unit test that works like this. It's pretty hard to assign n to a concrete function argument ...
    Usually it's 1, 2, maybe 3, probably -1. Spotting the important corner cases requires assembler skills, experience and a bit of a perverted mind; the former is something that's often neglegted as a CS basic. What happens at INT_MAX? Can some combination of arguments provoke an overflow? What happens when an int overflows as opposed to an unsigned int? Are my types guaranteed to be the size they are on my machine or can they change on other platforms?
    A lot of bugs are a result of such basic consequences of binary computing but people can't understand these if they've only learned about a variable as a kind of box that you can stick stuff into to take out later as opposed to a size-limited collection of bits that do interesting and uninintuitive things around their limits.


  • Considered Harmful

    @asdf said:

    True, but those calculus courses most CS students have to pass are still ridiculous. There is so much more useful math you could teach to CS students instead, like advanced statistics.

    +1
    I've seen people (well, one actually) get so befuddled with their complicated continuous-function methods from math class that they write pages of code trying to find the integral of a sampled waveform.



  • I can see it being done if the code you are testing is an expression builder.


  • Considered Harmful

    That still wouldn't give you an inductive proof, but even if it did, I think expression builders are not exactly frequent enough components to test that they would justify several semersters of maths class.

    Of course knowing how such a proof works is something is basic enough to be useful anyway.


Log in to reply