My Java class has these labs due on Saturdays and man I can envision so many people failing this course if they aren't super dedicated. Here is an example of one of our labs just a few weeks into the semester.
Prompt:
import java.util.Scanner; public class TextMsgExpander { public static void main(String[] args) { /* Type your code here. */ Scanner scnr = new Scanner(System.in); String userInput; System.out.println("Enter text:"); userInput = scnr.nextLine(); System.out.println("You entered: " + userInput); System.out.println(); if (userInput.indexOf("BFF") != -1) { userInput = userInput.replace("BFF", "best friend forever"); System.out.println("Replaced " +"\"BFF\"" + " with " + "\"best friend forever\"" + "."); } if (userInput.indexOf("IDK") != -1) { userInput = userInput.replace("IDK", "I don't know"); System.out.println("Replaced " +"\"IDK\"" + " with " + "\"I don't know\"" + "."); } if (userInput.indexOf("JK") != -1) { userInput = userInput.replace("JK", "just kidding"); System.out.println("Replaced " +"\"JK\"" + " with " + "\"just kidding\"" + "."); } if (userInput.indexOf("TMI") != -1) { userInput = userInput.replace("TMI", "too much information"); System.out.println("Replaced " +"\"TMI\"" + " with " + "\"too much information\"" + "."); } if (userInput.indexOf("TTYL") != -1) { userInput = userInput.replace("TTYL", "talk to you later"); System.out.println("Replaced " +"\"TTYL\"" + " with " + "\"talk to you later\"" + "."); } System.out.println(); System.out.println("Expanded: " + userInput); } }
It's actually not too difficult if you read the material and can think like a computer, but the professor has already said that most of the class isn't even doing the participation activities which anyone with very little skill could do in a few minutes.
-
Quote
the professor has already said that most of the class isn't even doing the participation activities which anyone with very little skill could do in a few minutes.
Yeah, welcome to CS university courses... some people just aren't cut for it.
On a side note... ugh, Java
-
Java is my first real programming course and so far I actually like it. In High School we had a game design class that used Construct, and tbh I think that class really prepared me in terms of mindset and how to approach the task at hand.
Professor said she didn't recommend java as a first language, but I'm trying and doing pretty good so far!
-
I can literally do anything but program. But I have to pass the classes for the major
-
Yeah, Java works if nothing else... but frankly I'd rather use almost anything else if given a choice. Want something easy and with wide support? Python. Want something fast? Rust/C/C++. Android development? Kotlin (even if it uses the JVM, at least the syntax and type system are sane). Web development? Go/Ruby/JS/Python/Elixir...
There's something I inherently dislike about a language that requires the use of an IDE with complex automation tools to compile anything larger than hello world.
-
Yeah, like I said I'm rather new so I haven't experienced any of the conveniences of other languages. Thankfully this CS course uses ZyBooks and all of our coding can be done inside its web interface.
Getting an IDE to work on my computers was very frustrating as they are all different and have their own errors if you don't set them up properly.
-
Try python, it lets you do a lot with little effort and you can just use a text editor.
-
oof, OOP is out of fashion... all the cool kids do functional!
-
Functional is one helluva drug.
...
I'll leave now.
- Sauron and DrMacintosh
- 1
- 1