[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Hey /g/, I want to start learning C right away. I got Learn C
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 95
Thread images: 6
Hey /g/, I want to start learning C right away. I got Learn C The Hard Way in pdf. I'm not willing to switch to GNU/Linux again right now, so I want to stick to windows.

I think I'm ready to learn, but I still need to choose a compiler. I have Visual Studio 2013, but some /g/uy said to avoid using it. Can you guys recommend me a good compiler?

And any tips? Thanks bros.
>>
TDM-GCC or Cygwin. Or virtual machine with Linux.
>>
>>42612753
I've tried both. Kept getting errors. I could be retarded. But I'm not sure.
>>
>>42612765
Like what? Be descriptive.
>>
>>42612799
Sorry I don't remember. This was last year when I was trying to cook roms for Android.
>>
File: gp2x.jpg (15 KB, 430x340) Image search: [Google]
gp2x.jpg
15 KB, 430x340
Why not CodeBlocks with mingw?

Back in 2007 I used BloodshedDev-C++ - it even had inbuild C-tutorials
>>
>>42612811
Then try it again now? Or install Ubuntu or something on a VM or even a spare computer and do it there.
>>
>>42612879
This.
And Visual Studio is fine too, unless your name is Richard Stallman.
>>
can't decide between C, java or python myself.
>>
>>42613917
Java and python are both slow and terrible.
>>
>>42613917
C
>>
>>42612717
>I have Visual Studio 2013
Well fucking uninstall that shit. Get yourself a REAL text editor.

>Can you guys recommend me a good compiler
mingw-w64

>>42613917
C is love.
C is life.
>>
>using anything but vim or emacs for anything
>current year of our lady of discord
>>
>>42613924
>>42613929
>>42613930
3 votes for C, can't be wrong

Can you explain to someone who does not yet understand almost anything about programming, why choose C?
>>
>>42613957
Because you don't want to choose java or python since those are utter shit.
>>
>>42613957
Another C fag here. You'll learn a great foundation for learning other languages and how programs generally work at the core.
>>
>>42613957
>why choose C?
-It's much closer to how a computer actually works than other languages
-It DOESN'T hold your hand; it forces you to learn by fucking up
-Teaches you about memory management
-Simple
-Fast
-Fucking almost everything else takes things from C
-C works fucking everywhere
>>
>>42613957
C stands for Cool.
C++ stands for Cool++.
Java stands for "Jews are very awesome".
>>
>>42612717
>he thinks visual studio is the compiler
you wouldn't last in Loonix anyway.
not unless you apply yourself more in general.
>>
>>42613988
>>42613996
Alright, that's convincing

>>42614012
What about C++?
>>
>>42614031
Learn C first, after that C++ is just extra shit on top if you really need to learn it.
>>
>>42614031
>What about C++?
A bastardisation of C.
Learn C first, and C++ later only if you want to.
>>
>>42614042
>>42614044
Seems convenient.

Guess I'll download that book OP's talking about too. Thanks.
>>
>>42614017
a bit harsh
>>
>>42614017
wow a real hax0r omg
do you have a neckberd
>>
>>42612717
gcc, clang
switch to BSD if you don't want to use Linux
>>
>>42614213
>gets called out for being wrong
>insults
>still expects help
Fuck off.

Kill yourself
>>
>someone on /g/ told you to avoid using the most comprehensive IDE in the world so therefore I must!!!

retard
>>
>>42614263
wow y ar you so angri m8
did ur waifu pillow refuse to hav sex with u
>>
>>42612717
>but some /g/uy said to avoid using it.
here's a tip from another /g/uy: test it out
>>
>>42614286
Who the fuck writes c in visual studio these days.
>>
File: 4RNUh.jpg (73 KB, 490x386) Image search: [Google]
4RNUh.jpg
73 KB, 490x386
>>42614291
Because you are a shitheel scumbag who should have been left in a dumpster at birth.

This isn't angry. I'm not even that guy you insulted.

You are a sub-human piece of garbage. Your suicide would make the world a better place. It was a logical utilitarian solution that this current post of yours added another datapoint to support my conclusion.

Sorry, every breath you take is a net negative value to the world.
>>
Learn swift, Apple is the future in terms of computing.
>>
>>42614420
wat the fuk did u fukin sey to me u fukin bitsh
i am traind in gorilla warfar
ur fuckin ded kido
>>
>>42614540

At least be funny if you shitpost

2/10 for getting me to respond
>>
>>42613917
Java, it's way more commercial.
>>
>>42614636
so os Miley Cyrus
>>
>>42613917
Java or C#, once you know one you know both
>>
File: 08HAMISH-articleLarge.jpg (64 KB, 600x400) Image search: [Google]
08HAMISH-articleLarge.jpg
64 KB, 600x400
Why choose C over C++?
>>
>>42613917
Python is good for beginners

If your not a beginner, you can probably pick it up in like 3 days.
>>
>>42616319
I don't like to treat others as objects.
>>
File: i am enlightened.png (695 KB, 833x478) Image search: [Google]
i am enlightened.png
695 KB, 833x478
>>42616603
>not treating everything and yourself as an object.
It is good practice.
Don't let feminism cloud your clarity.
>>
>>42613917
Depends what you want to do. If you just want to code simple programs to speed up your workflow or have fun, python is cool. If you want to develop android apps or GUI application, Java is good. If you want to have an honorable knowledge about programming and computers, C is the way to go.
>>
>>42612717
pic related?
>>
>>42613957
>why choose C?
because if you understand c you will understand everything else

c is used fro windows and windows software
>>
Well I learnt c++ as my first language. Have I lost something having not starting just in c?
>>
>>42617563
No.
>>
>>42612717
Download virtualbox, download an ubuntu / linux mint / elementary OS iso, install it in virtualbox. Dead easy.
>>
>>42617563
I bet you don't even know how to implement basic data structures. That's what you lost. However you gained easy access to complex data structures.
>>
I'll give you a reason not to use C. It starts with an "f" and ends with a "ree."
>>
>>42617563
Yes. You're probably suffered brain damage, having started with C++.
>>
Ok, so small weirder question here from a different person: What language is best to go into for game developement?
>>
>>42617563

I started with C++ too.

No regrets here.
>>
>>42612717
Get Notepad++ or Sublime Text 2 (if you don't mind non-free software). If you start off using an IDE you'll be useless without one.

As for which language to start off from, it doesn't really matter. Read the wikipedias on C, Java, Python, and Javascript and pick whichever one you like.
>>
>>42617981
Fork Tree?
>>
>>42612717
OP, download debian or ubuntu and do a:

as root:
apt-get update

apt-get install build-essential


or if using sudo(like ubuntu):
sudo apt-get update

sudo apt-get install build-essential


This will set you up to start learning C, make a new file, hello.c and type:

#include <stdio.h>

int main()
{
printf("Hello, /g/!\n");
return 0;
}


Then compile it with:
make hello


You will see a new executable in your working directory, named 'hello'...

running:
./hello


should print

Hello, /g/!


From there, get a book - I'm using 'The C Programming Language", some feel it's a bit outdated and you may want to get a suggestion from someone else(esp if you have no programming experience).

If you are a babby(no offense), I'd start with ubuntu.
>>
>>42618037
C++
unless you hate performance, then java
>>
>>42618214
Not OP, but Make? I thought you use the gcc command to compile.
>>
>>42612717
Install this:
http://nuwen.net/mingw.html

You'll be up with x64-native and GCC 4.8.2, Boost 1.55.0, and Git 1.8.5.2 in 10 seconds.
>>
>>42618229
make runs the c compiler
>>
>>42618229
well, gcc is the compiler and make is a toolset to build programs. When you build from source and/or start writing more complex programs, make will be used so it's a good idea(IMO) to get started with it immediately.
>>
File: C_Sharp1.png (34 KB, 256x256) Image search: [Google]
C_Sharp1.png
34 KB, 256x256
C# master race
>>
>>42617563
No, and you won't have to unlearn any bad habits from C.

Stroustrup: No. C isn’t simpler for C-style programming than C++ is, nor “closer to the hardware,” nor indeed more efficient. I have yet to see a program that can be written better in C than in C++. I don’t believe such a program could exist. By “better” I mean smaller, more efficient, or more maintainable. The myth that “C is simpler and more efficient” have caused (and causes) untold numbers of beginners to concentrate on obscure workarounds and difficult-to-master techniques, rather than learning how to use more powerful supporting features. Many then fall in love with their obscure and complex code, considering it a sign of expert knowledge. It is amazing what people can fail to learn when they are told that it is difficult and useless. The only reason I know of to use “plain C” rather than a suitable subset of C++ is lack of tool support on a given platform.
>>
>>42618275
>being basically locked to windows
>inb4 muh mono
it's shit. C# is good if you arent a freefag and only want to use/sell windows products
>>
>>42618284
Or make yourself more marketable, after learning C# you can pick up Java, then have a job.
>>
>>42618284
I use primarily windows so it suits my needs.

And as >>42618296 said it's marketable.
>>
>>42618296
>>42618301


>java
Dude, you are going further into the rabbithole..

But you are both right, unfortunately many many jobs are for java/c#.
Having said that, someone who knows their shit in C or C++ is worth their weight in gold

>keep being a shit level programming monkey
:^)
>>
>>42618037
C++ is by far the most common language vidya is developed in, and for good reason. These AAA companies aren't either stupid or ignorant. Performance is critical to their industry, but reasonably fast turnaround of huge projects is also highly important. They typically are dealing with huge codebases, and integrating with huge array of pipeline tools. Good abstractions are necessary to make this work well, and make relatively rapid turnarounds possible.

Solution? There's only one at the moment--C++.
>>
>>42618241
Although turnkey distros are great for fast deployment/testing, for a babby I'd say it's best to start with a easy to use distro with smart default configurations(ubuntu, etc). At least that way he/she can get familiar with how it all works and not expect everything to be working OOB
>>
>>42618312
have fun programming virtual waifus in your basement while other people actually have a job
>>
>>42618334
This isn't a distro. It's a MinGW64 with toolchain you cant install in 10 seconds on Windows.
>>
>>42618350
>can*
>>
>>42618337
Hey, I do have a job!

>sysadmin

It isn't primarily programming though.

Like I said, YOU ARE RIGHT, and most codemonkey jobs are going to be Java/C#.

>>42618350
whoops, probably shouldve went to the site, I was thinking it was a turnkey distro. My bad.
>>
>>42618375
yeah I know, just bugging you
>>
>>42618284
>it's shit
Why do people constantly say Mono is shit without providing any reasons? Its an implementation of C# 3.0 for other OSs and it fucking works, it even outperforms Microsofts runtime in some areas.

Is it because certain frameworks like WPF that have external dependencies and won't work with it? That has got nothing to do with Mono but with how WPF is written.
>>
>>42618375
>whoops
Nprb. OP's
>I'm not willing to switch to GNU/Linux again right now, so I want to stick to windows.
is why I recommended this approach instead of just using Linux Mint instead, which of course would be alot better for programming C in, and very easy to get started in for Windows users.
>>
>>42618391
For sure, same to you.

>>42618431
>I'm not willing to switch to GNU/Linux again
>not

Fuck, I am just retarded today - read that as
>I'm willing to...
>>
>>42618424
tbh, I haven't tried it since maybe 2011, and it was(iirc) in it's infancy. Maybe I'll try it again - but with the sheer amount of truly portable, cross platform languages I don't see the point tbh.
>>
I wish I could make the jump to GNU/Linux, then I could actually be productive and learn a language instead of just posting about learning it and switching books as soon as I pass the basic sections.
>>
>>42618634
Why can't you jump to it?
>>
>>42618663
I would if I had a desktop I could use for gay men and things that just don't work on GNU/Linux, but I only have my little laptop.
>>
>>42618682
Linux Mint Cinnamon is a very easy distro to pick up. Try running Windows apps under the latest Wine (be sure to also install Playonlinux and use that as your front-end for all Wine-based program installs). That will probably cover the majority of Windows applications on Linux issues for you. Barring that, create some room on your laptop for another partition, install Mint on it, and dual-boot with it.

That way, you'll have an easy distro, all the power of writing software on Linux, and you can still use your apps you need?
>>
>>42618764
>>42618682

I suggest the opposite, download virtualbox and run a gnu/linux or *bsd variant in a vm.
>>
>>42618780
That works too, but I like the perf of native myself. VMs are too laggy for me on my current hardware.
>>
>>42618790
>not using cli only installs for development
>>
>>42618806
True, b-but
>muh Steam gaems
>>
>>42618820
Valid reasoning.
>>
>>42617494
Pic is kinda indirectly related... cause it's my ex
>>
>>42613917

Aren't these generally different use cases? I'm just a dilettante but my simplistic understanding was that C and its variants do the heavy lifting (OS and serious apps), Java allows cross-platform use, and Python is simple and is good for writing apps that run on top of C.
>>
>>42620933
Your ex is related to you?
>>
>>42614677

Miley Cyrus gets paid, which is why OP wants to learn a language to begin with.

>implying programmers ever get paid to make works of art
>>
>>42621027
Java and cross platform is pure marketing bullshit. C# runs on every platform as well, that is if it has .net. Java is only "platform independent" because they left out every function that doesn't work on all platforms. You can load them as libs though, but then your code only runs on one platform. Also the JVM performance is considerably worse on any non-windows platform. If you wanted do develop cross platform you'd gave better luck with some script language.
>>
>>42621072
Java shills get paid too. May point is that popular doesn't mean good.
>>
>>42612717
>>42620933

OP, there's a correlation between your hot chick becoming your ex and your wanting to program.
>>
Let's say there was an open source project for a mobile device OS and it wasn't AOSP (Java). What language should it be written in?
Thread replies: 95
Thread images: 6

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.