Open Side Menu Go to the Top
Register
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** ** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD **

04-18-2018 , 12:18 PM
You should try golang. It's basically a modern version of c with simple improvements.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 12:20 PM
Quote:
Originally Posted by jmakin
getting much stronger at bash/vim/gdb, classmates remark at how quickly I do things in the lab lol. also, this is my first heavy exposure to C and I'm really enjoying it. IMO everyone should start out by learning C, I have no idea why they start with java/python.

one small irritating thing, I can't quite figure out how to yank an entire file in putty and paste it into windows.

ggVG will select an entire file, but multiple different methods of yanking doesn't yield anything. copy pasting from windows into putty is fine.
sometimes my coworkers comment on all the shortcuts I know for VSCode. I feel like theres a lot to improve.

one thing I dont understand, and I see it all the time, is ppl that continually do things suboptimally and slowly. like, someone will go to the mouse and highlight the text to copy an entire line when you can just hit ctrl+c.

or ctrl+p will let you search the filenames and yet ppl still will go the actual text search which is infinitely slower.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 12:25 PM
Quote:
Originally Posted by jmakin
getting much stronger at bash/vim/gdb, classmates remark at how quickly I do things in the lab lol. also, this is my first heavy exposure to C and I'm really enjoying it. IMO everyone should start out by learning C, I have no idea why they start with java/python.

one small irritating thing, I can't quite figure out how to yank an entire file in putty and paste it into windows.

ggVG will select an entire file, but multiple different methods of yanking doesn't yield anything. copy pasting from windows into putty is fine.
If you right click on the upper left corner of the Putty window you can see a "Copy all to Clipboard" command and "Clear Scrollback." You can use these to copy your entire scroll buffer to the clipboard. You can increase the number of lines held in the scrollback buffer in the options for Putty. Cat the file to the buffer then copy the buffer to the clipboard. Filezilla is also a pretty fast way to grab files from a server on a windows box. Or get a Mac and learn scp.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 12:30 PM
I think the problem with teaching programming is to a certain extent you have to teach everything before anything makes sense. With C you have to understand pointers fairly quickly and that abstraction is the first hurdle for learning to code. Hiding that until later is why higher level languages are thought to make better teaching languages. YMMV but remember that your view of C now is colored by your knowledge of programming other languages...

Last edited by kerowo; 04-18-2018 at 12:41 PM.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 12:45 PM
Right, but I'm thinking more of my former learning experience early on rather than what I know now.

For instance, your very first Java program -

Code:
System.out.println("Hello, World.");
There's sooo much going on here that's absolute mind boggling at first. System? what are the dots for?

And then your second Java program:

Code:
Scanner in = new Scanner(System.in);
String str;
System.out.println("What is your name? ");
str = in.nextLine();
System.out.println("Your name is " + str);
There's soooooo much going on here. Especially the scanner class line. How do you wrap your head around that? I couldnt for a long time.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 12:57 PM
But look at C:
Code:
#include<stdio.h>

main(){
    printf("Hello World");
}
What is that comment? What is stdio.h? Which leads to header and object files. What is main()? How does printf work?

It may seem better now but it's still pretty complicated. I'm not saying Java is a better choice, I learned basic on my own then Cobol at school. I don't know what I'd pick today, something interpreted so it's easy to see what is happening when you make changes. Something you could introduce functional programming with but was still procedural. I don't know what that is.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:20 PM
Come on, anyone could read that line and know what’s happening.

System.out.println is just so typically java and convoluted.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:23 PM
Seems roughly the same as printf() to me, but YMMV.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:27 PM
my first programming class was a terrible experience, taught by a tenured middle aged woman who spoke crappy english and didn't know java at all. she got her degree when punch cards were used.

so to a large degree I just had to figure it out on my own and java didnt seem very inviting to that at first.

python's on the other end of the scale, easy syntax but I feel it obscures too many low level things. I know the thinking is that java is the best of both worlds but meh.

it's so unlike me to hate on java so much but man it's really getting to me lately.

i am a big proponent of doing math in pen because it forces you to think before you write anything down to paper, which reduces the errors you make and (usually) results in cleaner math. C feels like the "writing math in pen" version of programming to me.

sorry for the rambling, i know this discussion's been had ad nauseum here before
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:34 PM
No one has mentioned:

public static void main(String args[])

Try explaining that to a newcomer.

Sent from my SAMSUNG-SM-G925A using Tapatalk
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:36 PM
at least main args are optional in C lol
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 01:50 PM
I worked with a prof that used Scheme as a beginner language and one big reason was that students could completely understand everything in the code he showed right from the start.

Put me in the camp though where I don't think there's any meaningful difference between the C and Java "Hello World" programs.

JMakin, what are the low-level things that you feel like Python obscures?
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 02:00 PM
Line endings...
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 02:04 PM
What a ridiculous conversation. Verbose boilerplate code that doesn't need to be explained to beginners is like the last reason to choose a language.

I still think you gotta go applications/goals first. Java, C++, C#, or Python are all much better at solving generic problems and getting into algorithms and data structures.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 02:09 PM
Quote:
Originally Posted by jjshabado
I worked with a prof that used Scheme as a beginner language and one big reason was that students could completely understand everything in the code he showed right from the start.

Put me in the camp though where I don't think there's any meaningful difference between the C and Java "Hello World" programs.

JMakin, what are the low-level things that you feel like Python obscures?
Pointers, for one
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 04:16 PM
Quote:
Originally Posted by saw7988
What a ridiculous conversation. Verbose boilerplate code that doesn't need to be explained to beginners is like the last reason to choose a language.

I still think you gotta go applications/goals first. Java, C++, C#, or Python are all much better at solving generic problems and getting into algorithms and data structures.
agree with this. give me a language that makes it easy to print out the fibonacci sequence.

then give me a language that makes it easy to print stuff on a web page, ie make a web app.

seems that is best beginners. at least for me, I like to do things.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 04:22 PM
Quote:
Originally Posted by Victor
agree with this. give me a language that makes it easy to print out the fibonacci sequence.



then give me a language that makes it easy to print stuff on a web page, ie make a web app.



seems that is best beginners. at least for me, I like to do things.


But the scope of a CS education doesn’t really involve a lot of “building” things and i think focusing more on CS in the beginning part of the curriculum would be far more beneficial to students and be a good stopper for people who can’t hack it. I know a few people who couldn’t really hack it in upper division CS and ended up dropping out.

I honestly had a very different idea of what the major would be in years 1/2 than by the time I hit upper divs and it was quite jarring/a little upsetting.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 04:31 PM
Even more of a reason to focus on data structures and algorithms. The low level C stuff you're "enjoying" now is pretty simple to grasp and doesn't usually translate to other domains as much.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 04:51 PM
Quote:
Originally Posted by saw7988
What a ridiculous conversation. Verbose boilerplate code that doesn't need to be explained to beginners is like the last reason to choose a language.

I still think you gotta go applications/goals first. Java, C++, C#, or Python are all much better at solving generic problems and getting into algorithms and data structures.
Depends on your goals, but if we're talking CS programs, it seems like a pretty good goal to have students actually understand what they're doing.

If you're talking a "get you out in the real world as fast as possible" program, then sure you gloss over a bunch of stuff with "trust me, this works".
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 04:52 PM
Quote:
Originally Posted by jmakin
Pointers, for one
I've never really understood the obsession with the importance of pointers in education.

Not to say they're not important, but lots of things are important.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 05:14 PM
Quote:
Originally Posted by jjshabado
I've never really understood the obsession with the importance of pointers in education.

Not to say they're not important, but lots of things are important.
I think it's like Algebra, some people have no problem with that substitution and some people just take forever to get past a letter being a number.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 05:23 PM
Quote:
Originally Posted by jjshabado
Depends on your goals, but if we're talking CS programs, it seems like a pretty good goal to have students actually understand what they're doing.

If you're talking a "get you out in the real world as fast as possible" program, then sure you gloss over a bunch of stuff with "trust me, this works".
I think saw's point still stands cause you can do either with a language like Java. You're not going to explain what public static void main all means when you're introducing "Hello World" but you learn those details before too long. Any language you learn will follow a similar path of using syntax and black box libraries you don't fully understand before learning how it all works.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 06:43 PM
Quote:
Originally Posted by saw7988
C should probably be taught at some level at some point in a CS curriculum. But when/where depends on the goals/courses. First course? Definitely not. I think usually you want to be starting off with something that teaches more core/common/conceptual topics, maybe either Python or C#, and start to learn some basic patterns/algorithms. C is great for an OS course or something later on.
I'm having trouble figuring out what "core conceptual topics" you want to start with that aren't in C. It has all the basics you have to get out of the way for any language: loops, conditionals, functions, variables, etc. All your intro algorithms are going to be loops, recursive functions, arrays and numbers. It has a tiny syntax compared to almost any language.

C is like a toy teaching language that accidentally happens to be really good to do Real Work in.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 07:45 PM
Quote:
Originally Posted by d10
Any language you learn will follow a similar path of using syntax and black box libraries you don't fully understand before learning how it all works.
That's the thing, its not true for any language.

If you're taking beginner students (little to no programming background) it actually takes quite awhile for them to understand all the pieces of a Hello World program. Especially if we're going for actual understanding of concepts like Objects and static methods.
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote
04-18-2018 , 07:49 PM
Quote:
Originally Posted by kerowo
I think it's like Algebra, some people have no problem with that substitution and some people just take forever to get past a letter being a number.


I still do stupid **** with pointers all the time, just like I do stupid **** in math all the time
** UnhandledExceptionEventHandler :: OFFICIAL LC / CHATTER THREAD ** Quote

      
m