The Programming Thread

Discussion in 'Miscellaneous' started by MoreMoople, Mar 19, 2020.

?

Do you program?

Yes, all the time! 8 vote(s) 23.5%
Yes, sometimes :) 12 vote(s) 35.3%
Yes, but just for fun :D 2 vote(s) 5.9%
I tried it once... 7 vote(s) 20.6%
Nope. Nope. Nopity Nope nope. 4 vote(s) 11.8%
I don't, but I would like to :) 1 vote(s) 2.9%
  1. Hello, everyone :)

    I know there are a lot of people here that enjoy programming, from people that do it for a living, to people that do it just for fun. Maybe you don't know how to program, but want to learn. Well, you've come to the right place!

    Since a lot of us are stuck inside right now, I would like to share a list of resources for people interested in learning how to program. :)

    ---------------
    Useful Resources for Learning how to Program

    Sololearn:

    Sololearn is available both as a mobile app and as a website. It is beginner-friendly, and an enjoyable way to learn the basics of various programming languages. It offers friendly community discussions, as well as programming challenges.

    What can you learn on SoloLearn?
    SoloLearn offers courses in HTML Fundamentals, CSS Fundamentals, JavaScript, AngularJS, C++, Java, Kotlin, C#, Python 3, C, PHP, Ruby, Swift, and more! Upon completion of each course, you receive a free certificate.

    Khan Academy:

    Khan Academy uses a lot of videos to teach programming. After each video tutorial, you complete exercises and projects to strengthen your skills. You can publish your projects and receive peer feedback. Khan Academy has a point system in place throughout the website, which many people may find motivating.

    What can you learn on Khan Academy?
    Khan Academy offers courses in HTML/CSS, Javascript, and SQL. It also offers courses in Computer Science and AP Computer Science Principles.

    W3Schools:

    W3Schools is a well-organized website with information for people learning how to program. It provides many examples, as well as exercises and quizzes.

    What can you learn on W3Schools?
    W3Schools offers information about HTML/CSS, JavaScript, Python, Java, C++, and C#.

    freeCodeCamp:

    freeCodeCamp offers long courses for certification. Note that these courses are better done on Chrome or Firefox.

    What can you learn on freeCodeCamp?
    freeCodeCamp offers courses in Basic HTML and HTML5, CSS, JavaScript, and more. The estimated completion time for each full certification course is about 300 hours.

    tutorialspoint:

    tutorialspoint teaches mostly through a written guide. It provides a lot of information, but I would recommend starting with the other resources first and then using this for additional information.

    What can you learn on tutorialspoint?
    tutorialspoint offers tutorials in Java, Python, C, C++, Python, Scala, and more!

    Stack Overflow:

    Stack Overflow is a great place for asking questions and helping others solve their programming issues. You can find answers and explanations for a wide variety of things that you may come across.

    ---------------

    For the younger crowds or beginners

    Code.org:

    Code.org offers a wide variety of fun block coding challenges. It is commonly used in schools and is a great way to get kids interested in computer science. There's even a Minecraft tutorial in the hour of code section!

    Scratch:

    Scratch uses a block language that is fairly simple and fun to learn. You can create your own backgrounds and sprites on Scratch, and even make animations or games!

    ---------------

    I will be adding more resources to this list as I discover more things and explore the other ones I've found. If you have any questions or suggestions, feel free to post below. :)

    You are welcome to use this thread for general programming discussion, programming/computer science memes, and other related things. Happy programming! :D


    I am currently a student and planning to pursue a degree in Computer Science with the intention of becoming a Software Developer. My first introduction to computer science was 7 years ago with Scratch (scratch.mit.edu) on a Raspberry Pi that my father gave me as a gift.

    As of May, 2020, I have completed five computer science classes. Next year I will be studying it by myself because I have run out of available classes at my school. If you have any suggestions for what I should do then, let me know! :) I have experience with HTML/CSS, JavaScript, Java, Python, Netlogo, and using Arduinos.

    I am a member of the National Center for Women & Information Technology community. I am hoping to continue with that for many years to come. :)

    I intend to post projects on here every once in a while. I have not done anything super complex and exciting, but one of my current personal projects is creating a website with resources for people that have Auditory Processing Disorders!

    Share your experiences with me! I would love to hear them.
    -MoreMoople
  2. As a college student currently bashing their head into the desk due to the large amounts of code I have to write. It's always fun to see others also on the same path as me. I am also studying Computer Science to be a Software Developer. I have learned (and mostly forgot *shrug*) HTML 5, and Python. I'm currently attempting JavaScript.
    Funny, I also first started using Scratch as well, we used it in Middle School and I kept going haha.
  3. Gonna share my experiences with programming thus far. Would love to hear everyone else's experiences.
    I have not done much programming in a while. In fact, in all likelyhood I will be pursuing a career in web design. Not sure what it is but HTML, CSS, and the other common web related languages are fine to me (I still consider myself to be an ammeter- and since I havent done any programming in over 6 months I have definitely forgotten alot lol) but when it comes to that c++ class I took... don't even want to think about that (I got a like a high C in the class iirc :()...

    I found out that I somewhat liked programming (still not 100% committed to it- caused much rage for me lol) back in high school. I took a digital design class and the teacher wanted us to find something computer related and teach it to ourselves (the teacher self-taught himself web design and systems management iirc so he wanted the students to learn for themselves too (of course he would help you if you asked but he wanted you to solve your problems on your own).

    So, my idea was to use GIMP and draw my top ten favorite tv show characters and list them on a local site using css and html. I have one of the drawings saved in my google drive so here ya go!



    Anyways, I worked on that for weeks and weeks (if I am being honest, my terrible drawings took most of the time xD). Sometimes a friend of mine in class would even draw the images for me (I think out of the ten, I drew 5 (the one posted above was mine :p), so he got to add more drawings to his "portfolio" and I had some... better stuff for my site. At the end of the semester we had to show the whole class what we did and it was tons of fun. I had alot of fun with that project but occasionally I needed a break from it, so enjoy this image I made on a day in class that I did not feel like doing any programming:
    Not sure if this image is against the rules or not (its sort of frowned upon to bring politics into things here on EMC, so remove the image if you must :).




    Edit: Oh and I also did some programming in the robotics class I took in high school, but I honestly don't remember any of it haha.
  4. My name is actually a reference to my website, https://waffle.coffee/. It's not much at all, literally just my email (that I don't use anymore, why is that still up there), but I have a few other hidden pages that are more interesting. (I stole all of my code from W3Schools and adapted it to my needs. Day in the life of literally any web dev/programmer, haha.)

    Moople: another good resource to add would be Stack Overflow. Whenever I'm trying to do literally anything technical, especially debugging, a Stack Overflow thread is in another tab. Highly recommended :D
  5. I'm glad to see people making use of the online resources that exist nowadays~

    When I did webdesign back in 2008, almost none of the resources that people have today existed then. Things were way tougher then. -- I'm glad to see how many resources are available, because I was able to pick up webdesign dabbling in my free time recently, and even self-teach myself some CSS. :)
    Lukas3226, 607 and MoreMoople like this.
  6. True true. Also, add stack overflow and EMC to the list. Stack overflow has almost any question you have, and if you need help there are a lot of people on EMC who will gladly help you, me included.
    Lukas3226 and MoreMoople like this.
  7. Update: I added Stack Overflow to the list, as well as a small section aimed more at young people. :)
    That's cool! Thank you for sharing. :) Are you enjoying JavaScript so far?

    Getting a high C in a C++ class. The irony. :rofl: :lmao:
    I love your drawing!
    I remember seeing your website! Can't believe I forgot to add Stack Overflow :eek: Thanks for the reminder!
  8. It's okay, getting very difficult near the end. I had a firm grip of it at the start at least :p
    MoreMoople likes this.
  9. What do you mean with this?
    I don't think so!

    My biggest programming projects are Iter Lanatae, a video game which I made for my then best friend's 18th birthday anniversary (check out its soundtrack here, including game footage), and of course my Mandelbrot explorer. :) For my secondary education's thesis, I programmed RSA in Python.

    I currently have experience with the following languages (of course if you know a language you will be able to easily pick up similar languages, but it could still be interesting to list):
    • GFA Basic
    • GameMaker Language
    • C#
    • Python
    • HTML
    • Prolog
    • NetLogo
  10. Yesterday I learnt something interesting and unintuitive about Python... If you ever expect to work in Python in the future, please remember that this works the way it does. ;)
    Lukas3226, MoreMoople and 29672057602 like this.
  11. I have superior programming skillz šŸ™„

    A free of charge example:
    10 print "a response"
    20 goto 10

    More seriously.. Knowing how to program is good and all, but there's one thing even more important: being able to set up a proper design to work with, preferably one which also allows for future expansions.

    Too many projects often collapse under a chaotic structure after which the only alternatieve is to rewrite (huge) parts of the code to clean things up. And this has happened to dozens of large projects. Not even a predefined framework can protect you from this.

    (edit: I think the next part is better suited in this post, so I moved it)

    AND since I just got home again... I just realized I didn't mention my work and such ;) (it's a bit difficult to type from my cellphone ;)).

    I've been deep into programming, mostly BASIC and assembler on my C64 but after that things went quiet because there was no direct need for programming tasks within my work (Novell systems administrator at that time). Fast forward to a few years later and I came into contact with Sun Solaris through a Sparcstation which work was using to power their database. It worked like a magnet on me and I was quite motivated. So much that $company send me to two Sun Solaris trainings. That was also how I came more into contact with Linux again; because I couldn't afford a personal copy of Sun Solaris x86 at that time ("only" E 2k or something) I used Linux to keep my Unix expertise fresh.

    Alas; this is how I came into contact with both shell scripting as well as Java; Solaris relied heavily on Java, even their installers were programmed in Java. So I figured that learning Java would help me learn more about Solaris. I followed a self-study and became pretty experienced within the field. One of my best projects was writing a database synchronization controller between servers (very long story).

    This is also around the time when I discovered Sun Studio Java One and NetBeans, and I immediately loved the latter. And it was thanks to NetBeans that I came into contact with Visual Paradigm (the software can hook itself into several well known IDE's so that you can code & design at the same time).

    Well... over the years I've also become more exposed to Microsoft servers and the thing is... I'm an ICT freak. It's not just Unix or just Windows, it's the whole information technology and the cool things you can do within that field which fascinates me. This was at another job (and years later) but over the years I also learned more and more about the Windows' insights. Trust me when I say that there's a whole lot more to Windows than most realize. Simple example: mmc.exe

    Alas... even though I disliked C# through prejudice ("a simple Java rip off") I never plain out ignored it. I had already been exposed to the extreme lengths you can take some of the Microsoft tech: when I started my own company I relied on Microsoft Office because it was a standard and because I really came to enjoy the environment. It didn't take me long before I developed my own administration framework within VBA (powered by Word and Outlook).

    So: I would get a reminder in Outlook that it was time to send an invoice to $customer. I'd open Word, click my "New company document" macro and I'd select the name of the client and... wait... I think I can give a better example:


    Unfortunately I can't run this critter to give a better example; the last time I used this (yearsago) I was still using my trusty Windows 7 32bit environment, and as it turns out my "Outlook connector" addresses 32bit API's, so that snippet has to be converted for proper 64bit usage:

    I got the 'outlookconnect' Clipboard control class module from MSDN....

    But you get a rough idea here...

    Back to the story: so if I needed to create an invoice I'd simply create a new Word document based on my custom template after which I'd get a form where I could fill out an address and specify what kind of document it would be. The cool thing here is that my macro would then cross reference Outlook to extract the required info for that client. So say I had to bill EMC I could use: "llc" as name after which the routine would find "LLC" as the company name and retrieve all the extra data (postal address and such) from the database. Couldn't be easier!

    The best part was because I hooked this into Outlook I always kept track of which customers had received their invoice, even if a customer preferred regular mail over electronic mail!

    Getting to my point though: I've done so much with VBA that I also became curious about .NET, and C# in particular after which I discovered that C# may have been based on Java it's actually nothing alike. In many ways C# is much more flexible (and dare I say advanced) than Java is (keep in mind: writing within the context of a few years ago, I don't really keep up with recent developments anymore). But a nice example: partial classes...

    This triggered my attention towards ASP.NET because I grew tired of using Java EE and I disliked working with PHP (still do). I ended up doing an ASP.NET self study (also powered by many freely available courses courtesy of Microsoft & some of their partners) and that resulted in me doing more "web coding", and loving that as well.

    So yah... when it comes to developing / programming I've become quite experienced with shell scripting (= creating scripts for a Unix environment in order to make that environment 'do' something), I have a decent (yet dated) Java experience and right now I'm more involved with ASP.NET and sidelines involved with some C# projects.

    My main tools of trade at this time are Visual Studio & Visual Studio Code (I replaced NetBeans with the latter because I started to seriously dislike it, so now I do all of my sporadic Java coding within VS Code).

    pfffff.... I need to get myself a drink and celebrate the start of my weekend ;)
  12. Minecraft is one of these projects. :D
  13. Hello my fellow CS students :p
    Last week I finally got my Bachelors Degree in Computer Science delivered in the mail (it took them 6 month to print and sign everything after my last class was passed :/)
    With the COVID-19 situation, all my courses in the Masters program are online, and for a technical university the first week is surprisingly horrible structured, despite the missing video equipment.
    But I have to endorse two Profs that deliver very well done lectures online.
    One of them has experience with online courses and made a well accepted MOOC on Coursea, which Moople can add to the list of online resources ;) There, you can complete structured online courses. Participation is as far as I know for free, but to get a certificate after completion you have to pay. Areas are from CS and related fields, but als Business, Arts and Humanities, ... from universities and companies. You can even earn yourself a full Master's degree (it's expensive imo, but I'm not used to these prices here in Germany).

    Further, Google offers free online courses in their Digital Garage. Their course on Digital Marketing comes with a free certificate, other courses in Data and Tech, and Career Development are just for yourself to learn :p

    For my degree, I learned programming and usage of different programming languages and applications, including Java, C/C++, Bash, OpenMP, MPI, Haskell, Python, SQL, SPARQL, and Prolog.
    Now, I aim to specialize in IT-security and data science.
  14. Yes.. Minecraft as well as (parts of) the Linux kernel, MySQL database server, Apache webserver, PHP framework, NetBeans IDE.... it's seriously weird to see how all of those projects, even the semi-professional ones, managed to end up in a pile of chaos.

    This is one of the reasons I've become a huge supporter of so called structural or modelling languages. Things like UML and BPMN. The main reason why I've become such a huge fan of the Visual Paradigm modelling software (note: there's also a freely available community version, which is the only reason I feel comfortable to share the URL).

    It may seem like a waste of time: spending time on thinking what to code while you could actually be doing the coding right away, but stepping back a bit and trying to get a good idea about the structure of what you're about to set up (or work on) can seriously help you to make sure that things remain manageable.

    Better yet: it can also help you to think & brainstorm about problems before they might even happen, so that if you do get into the predicted situation it won't be as much of an issue as it might have been. In normal English: it may just be the trick you need to avoid having to add "temporary" workarounds to problems instead of immediately being capable of addressing the problem heads on. Simply because you could predict its existence and saw it coming.

    (edit: see above for removed contents) :)
    TomvanWijnen, 607 and MoreMoople like this.
  15. True! One of our teachers at uni greatly insisted on "eerst modelleren, dan programmeren" ("first model, then code"), but I still sometimes skip it. :oops: But if you start coding right away, you'll probably have to restart coding a few times. ;)
    ShelLuser and MoreMoople like this.
  16. Don't feel too bad... because the only reason I became such a fan of this workflow is because I also experienced issues myself quite a few times. When they taught this during my college days we also tended to ignore it.. I mean... "the code reads itself", was our motto. Thing is... it does, and it's a good motto. But does it still work after 2 years? ;)
    607 likes this.
  17. "Good programmers can write code. Great programmers can copy, paste, and adapt."
    Truer words have never been said ;)
  18. iā€™m not a huge fan of programming but i took a course last year where we used arduinos and fusion360 to make a robot that could move and knock stuff down lol. i much more enjoyed the engineering aspect of the project but it was cool to try programming! c+ was a nightmare for me because i had a horrible teacher!
    MoreMoople and 607 like this.
  19. this cracked me up lol :oops:
    Cyberazaz101, MoreMoople and khixan like this.
  20. Always document your code....

    Sure, if you open your project again next week. NP! Then a customer calls you about a bug 2 years later, now what?

    And you know the really cool part of all this? It can also apply to Minecraft, oh yeah.... :cool:

    I'll be honest: we kinda staged the scenery, but it's still true...

    Have you ever wondered why so many redstone fans use wool all the time? And of different colors too if it can be helped? Well, probably because of this:


    As I mentioned before we staged this because the sign is plain out impossible to miss if you teleport here. My point though... this sign tells you all you need to know about this circuit, provided that you know what it's supposed to do of course.

    This evening Aya asked me if my railroad transport still worked, we tested and it did. Then we looked at the redstone circuits (I always try to keep (teleport?) access to the circuits instead of just embedding them) and yeah; this sign says it all..

    What you're looking at: A railroad transport system which can move items from my main res to my 2nd (actually 4th) res. The system does 3 things:
    • If an item is detected: a minecart + chest is placed.
      • A stone block is also pulled away from the end of the rail.
      • The light above the 'loading chest' is turned off to indicate limited functionality.
    • If a minecart (+ chest) is present: all items from the 'loading chest' are transported.
    • If the 'loading chest' is empty the previously mentioned stone block is placed back.
      • If a shortage of minecarts is detected a light above the "refill chest" is lit.
    ... with a few sideway actions ;)

    Point being: reading that sign told me all I needed to know to tackle any possible specific issues.

    Light, rail (the block) or structural control (= checking if 'loading chest' is empty)... all pointed down.
    And I do this with all my builds...

    This:
    Note the sign? ;)
    Powers this:
    The left structure....

    In case you're wondering... I plant crops here, push a button and everything gets auto harvested. I pull the button again and I'm ready to replant. Problem: I'm a nitpick. Of course I don't want all floors to get harvested all the time. No: each floor should be 'harvestable' as well as all alike.

    Something like this:

    But the main thing which keeps this manageable (other than a TP sign) is a ton of colored wool and a regular sign which acts as a legend to tell me what circuit does what.

    The point being here though.... if you at least comment your code you'll always know what it does or is supposed to do. And yes: this even applies to redstone. And before anyone wonders: if you even wonder at all (shame on you!) then I can tell you that redstone stands at the very foundation of programming. It's programming in its most elementary form, somewhat comparable to assembly.

    There's a reason why some geeks & nerds adore Minecraft ya know ;)