Home Forums Off Topic textfugu.include?("rubyists")

This topic contains 11 replies, has 4 voices, and was last updated by  MisterM2402 [Michael] 11 years, 3 months ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #41290

    missingno15
    Member

    At work atm.

    Long story short (要するに)

    Thread is for all webdevs, programmers (same thing?), software engineers, CS majors/minors and super beginners like me to discuss these kinds of things. Like IT関係者向けのスレ

    In other words, a thread for me to ask all my super beginner questions about Ruby on Rails etc, chunky bacon, and CS in general ^^;

    #41299

    #41300

    I’m going into the 3rd year of a (4-year) CS degree. I don’t know anything about Ruby though…

    #41301

    missingno15
    Member

    What have you done so far with your CS degree so far though?

    #41328

    Senjougahara
    Member

    I’m going to be a senior year CS major next fall. Right now I’m an intern at a software company. My favorite language is Haskell, but I’m most fluent in Python, and right now work in C.

    #41329

    missingno15
    Member

    Cool, what experiences led you to know those 3 languages?

    #41330

    @Senjougahara: Haskell high-five! :D What a great language. My lecturer for functional programming in first year (in which we learned the language) was Philip Wadler, one of the guys who actually helped develop Haskell. Main research is on lambda calculus, I think. Pretty eccentric man. He’s worked at many different universities I think, so there’s a chance you’ve seen him too :D http://en.wikipedia.org/wiki/Philip_Wadler

    Languages I’ve covered so far in my degree (to varying uh… degrees): Java, Haskell, Python, C, MIPS assembly, Matlab, Prolog, SQL, XML. Java and Haskell have been the main ones so far but the others have been used in various assignments and whatnot. Definitely wouldn’t consider myself that good with any of them but have had the most experience with those two; they’re kinda dormant in my brain at the moment but if I had the time to revise a little, I could probably get back into using them ok.

    Other stuff I’ve covered: a lot of maths (linear algebra, calculus, probability, discrete maths), algorithms and data structures (searching and sorting, and stuff like linked lists, heaps, etc.), machine learning, first-order and predicate logic, formal and natural language processing. While I was great at maths in high school, uni-level maths was a massive step up and I’ve done pretty terribly at it so far :/ No more specific maths courses after the first two years though, so that’s something (not that we won’t be *using* the stuff we’ve learned so far, of course). Machine learning stuff was quite interesting but difficult at times. Really liked natural language processing.

    #41333

    missingno15
    Member

    Watching a video on Angular JS with sister

    @misterm2402 How different are the functions between Java, Haskell, C and Python?

    #41336

    What do you mean, like how is the syntax different? Functions in Haskell are pretty elegant, I think; being a “functional language”, the majority of Haskell programs are comprised of functions.

    myFunction :: Integer -> Integer -> Bool
    myFunction x y | x - y == 0 = True
                   | otherwise  = False

    So that’s saying take two integer arguments x and y and return a boolean (if x and y are the same return True, if not False), so in the interpreter you could type myFunction 5 3 and it would return False.

    It’s also got a cool construct that mimics set-builder notation from maths (think Python might have something similar too, can’t remember). Typing [ x | x <- [1..10], isEven x] gives you a list of all the even numbers between 1 and 10.

    Sorry, I just really like the Haskell…

    #41337

    missingno15
    Member

    As far as I know in my limited knowledge, some programming languages are better than others in some instances. If there were such instances where, lets say, Java was better than Haskell, I was hoping you could enlighten me on what they are.

    Typing [ x | x <- [1..10], isEven x] gives you a list of all the even numbers between 1 and 10.

    In Ruby, that would be:

    a = (1..10).to_a
    b = a.select { |x| x.even? }

    Thought it was interesting that the syntax looked familiar

    #41339

    missingno15
    Member
    #41347

    Well, just generally, lower-level languages like C and assembly are better if you want more control over how the processor is used and how memory is allocated. Java is very portable because it runs on something called the Java Virtual Machine – it’s kinda like a layer in between the Java code and the processor, the JVM dealing with differences in architecture so the code doesn’t have to. Matlab’s used for mathematical programming; we used it in a machine learning assignment for analysing large amounts of numerical data. Prolog programs are lists of relations – represented by facts and rules (the “knowledgebase”) – on which queries are run, with applications in AI.

    Sorry, that was kind of a shit answer – I’m really not great at explaining stuff like this, I’m sure there are other places online that do a better job :P While I mentioned Java’s portability, there are probably many, many other reasons why you’d choose it over Haskell (and vice versa).

Viewing 12 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.