[ 3 / biz / cgl / ck / diy / fa / ic / jp / lit / sci / vr / vt ] [ index / top / reports ] [ become a patron ] [ status ]
2023-11: Warosu is now out of extended maintenance.

/sci/ - Science & Math


View post   

File: 6 KB, 379x311, 1291816699032.png [View same] [iqdb] [saucenao] [google]
2606684 No.2606684 [Reply] [Original]

>>2606671
I've always wondered: How are programs programmed if there are no other programs to program with? What was the very first program and how was it made and with what language?

>> No.2606688

wires lots of wires

>> No.2606698

http://en.wikipedia.org/wiki/ENIAC#Programming

The ENIAC could be programmed to perform complex sequences of operations, which could include loops, branches, and subroutines. The task of taking a problem and mapping it onto the machine was complex, and usually took weeks. After the program was figured out on paper, the process of getting the program "into" the ENIAC by manipulating its switches and cables took additional days. This was followed by a period of verification and debugging, aided by the ability to "single step" the machine.

also learn to google

>> No.2606728

Then machine code entered with flip switches line by line.

Enter the ones and zeros of an 8 bit opp and press a button to push the opp onto the stack.


Then assembly which is essentially the same but you've got a simple text editor to do it in.

Next your text editor gets abstractions like labels for goto commands and shit like that so you don't have to keep track of the number of lines you added and change all the goto's in between.

Then some languages start popping up like fourtran cobal and basic.

and finally C is born and noting ever surpasses it ever

>> No.2606777
File: 337 KB, 1500x2149, language.jpg [View same] [iqdb] [saucenao] [google]
2606777

>>2606728
Pfft. Just you wait until we develop a computational language that merges symbol and meaning together and where every element modifies every other element so that the simplest change fundamentally alters the meaning of what the program does!

>> No.2606786

>>2606728
>and finally C is born and noting ever surpasses it ever
You had me up to there.

>> No.2606799
File: 335 KB, 1899x1105, altair_680_front_panel_right.jpg [View same] [iqdb] [saucenao] [google]
2606799

You don't NEED a program to program, it just helps a lot. If there is no logical interface to run a program on a new machine, you can use a physical interface instead - these days this is done with JTAG and another computer. Back in the day it was done with physical switches on the machine (pic related).

>> No.2606800

Assembler was made to write programing code into a computer that had a CPU with various different instructions based on the input, but how does that CPU perform those instructions?

Digital logic, the science of making a machine that can take input and produce output, using electricity in wires using logic gates, made from semiconductors that change the flow of electricity.

>> No.2606810

>>2606786

Shut up Java monkey.

>> No.2606811

>>2606786
There aren't any languages that surpasses C/C++ as the professional standard. Even it's new version, C#, hasn't been up to the challenge to do so.

>> No.2606818

>>2606810
Lol assuming I'm a Java monkey. I could be a SmugLispWeenie for all you know.

>>2606811
It depends highly on what you're doing, what the team is capable doing, target platforms, and so on. Anyone who ignores business constraints when making a business decision is retarded.

Also, I'm partial to C++ for performance critical applications where program size is not a limiting factor.

>> No.2606821

>it's new version, C#
Wat? C# is not a new version of C, any more than Java, C++, Obj-C, or D are. C# is a new language that shares a lot of syntax and concepts with those others.

PHP also shares syntax and concepts with C but no one calls it a new version of C.

>> No.2606827

>>2606811
>>2606821
Oh yeah, forgot to call 811 a retard. C# the new version of C? Gotta be an idiot or a Microsoft fanboy. C# started off as an obvious derivative of Java, and still shares more in common with Java than it does with C or C++. It also has the added benefit of basically only running on Microsoft shit.

>> No.2606833

If you can't do it in Fortran, do it in assembly language. If you can't do it in assembly language, it isn't worth doing.

>> No.2606839

>>2606833
Protip: C is largely superior to Fortran, except /maybe/ for hardcore number crunching.

>> No.2606853

>>2606818

If your business doesn't revolve around grizzled C gurus, get a new business.

>> No.2606861

>>2606839
Legend has it that Seymore Cray, inventor of the Cray I supercomputer and most of Control Data's computers, actually toggled the first operating system for the CDC7600 in on the front panel from memory when it was first powered on. Seymore, needless to say, is a Real Programmer.

>> No.2606875

>>2606861
>Did a painstakingly annoying process
>Makes him a real programmer
Yea... no. That argument does not follow. Maybe he is, but that shows at best that he's good, and highly dedicated.

>>2606853
Whatever fanboy. You're not going to have a reasonable discussion, so meh.

>> No.2606881

>>2606833

Says the man using the name pascal.

Turbo or plain jane, fag?

>> No.2606884

>>2606827
You are correct on all counts, but C# is a beautiful language. There has been a massive effort to adopt it on Linux with Mono. Unfortunately the majority of the community rejects their work just because MS invented C# and the Linux fanboys hate anything to do with them.

Mac OS is a whole different story, as Obj-C is now the only supported language. They used to provide Carbon for C/C++, but it's deprecated and 32-bit only. They used to provide Java Cocoa, but killed it.

For the record I am no fanboy. I have to use Linux, Windows, and Mac OS for work and they are all fine operating systems. Well OK maybe I am an AMD fanboy but that does not pertain to this discussion.

>> No.2606888

C ANYTHING has zero application in my industry.

It's simply too slow compared to native ASM.

Suck it, you non low-level fags

>> No.2606887

>>2606884
>Well OK maybe I am an AMD fanboy but that does not pertain to this discussion.
Acceptable. (~smile and wink~)

>> No.2606907

>>2606881
Delphi
>>2606875
Is a joke from the 80s
http://www.pbm.com/~lindahl/real.programmers.html

>> No.2606911
File: 21 KB, 400x363, 1295761387954.jpg [View same] [iqdb] [saucenao] [google]
2606911

>>2606888
i flip derp switches because it takes longer and that makes be a better programmer

>> No.2606910

>>2606907
Ah, lol, I see.

>> No.2606912

>>2606907

Don't bother. If Scientist tries to read that he will have a heart attack from the creative use of the English language. He has issues with that.

>> No.2606920

>>2606912
Nope. My problems are with nihilists, "no objective reality" nuts, and Platonic Ideal nuts. I have nothing against beauty and poetry.

>> No.2606930 [DELETED] 
File: 14 KB, 228x254, tcge0101.jpg [View same] [iqdb] [saucenao] [google]
2606930

MFW "Real Programmers aren't afraid to use GOTOs"

>> No.2606942

they've probably already answered you but still:
1. the processor understands only the assembler language in your case desctop PCs the assembler is x86 and x86-64
the raw language is just zeros and ones stored on a floppy disk for example
2. the moment you turn on your PC the processor accesses the BIOS information and decides where should it read the information from, let's assume that the bios setting is set to first bootable device the floppy drive
3. the processor uses the information from the BIOS and tries to read from the floppy
4. if there is a bootable floppy the processor starts to execute whatever is in the first blocks of the floppy(these blocks are called the boot sector)
it has a special code to know that the floppy disk is marked as bootable

and this is it..
you may use whatever machine you want to write on the floppy disk to make it bootable
all you have to know is the assembler and organisation of the PC

first computers used paper cards
where you cut specific places in the card to encode bits
in similar way you encode bits on the floppy drive

5. usually loads a second stage loader
6. the loader loads the kernel
7. the kernel recognizes devices and mounts the root fs
8. some initd and rc.d stuff and you have shell

>> No.2606949

>>2606930
If they're programming in BASIC, this statement would actually be true.

>> No.2606948

>>2606930
Real pogrommers aren't afraid to use GOTO

>> No.2606956

http://en.wikipedia.org/wiki/Brainfuck

>> No.2606975

>>2606930
Meh, I prefer code block leaping than GOTOs, I could never understand why anyone would use a GOTO, nor can I understand why it's even a big deal with people.

>> No.2606979

>>2606930
you should know that every loop uses goto on the assembler level
also in school they say that it's bad because it turns hell when you use goto in, out and between loops
but if you know what you're doing goto can save you a lot of time
it's bad for someone that's looking at your code but still it's your choice whether you use it or not
also debugging turns into a nightmare when you abuse goto

>> No.2606989

>>2606979
I have in all my professional C++ and Java coding life never seen a legitimate use of a GOTO which couldn't be more easily written with structured programming concepts. Not that they don't exist, but "don't no goto" is a highly useful guideline for some languages.

For C, which lacks RAII and automatic stack destructor calls, goto is a bit more useful as a poor man's Java finally clause.

>> No.2606995

>>2606975
cause it's faster than interrupting for function calls and growing the stack needlessly
not that it matters in OOP there it's unavoidable

>> No.2607018 [DELETED] 

+++++ +++++
[
> +++++ ++
> +++++ +++++
> +++
> +
<<<< -
]
> ++ .
> + .
+++++ ++ .
.
+++ .
> ++ .
<< +++++ +++++ +++++ .
> .
+++ .
----- - .
----- --- .
> + .
> .

>> No.2607042 [DELETED] 
File: 36 KB, 350x263, beluga (1).jpg [View same] [iqdb] [saucenao] [google]
2607042

Guys guys

>>>/prog/

NOW GTFO

>> No.2607058

I think the first thing that was programmed was unix and it was programmed in assembly
And assembly was written in binary

>> No.2607074

>>2606989
>I have in all my professional C++ and Java coding life never seen a legitimate use of a GOTO which couldn't be more easily written with structured programming concepts.

That's because you're a newfag and never touched BASIC in the early 80s.

>> No.2607079

>>2607058
UNIX was done in C/C++. In fact it sometimes show in it's design, the same goes for any Linux or OS' that models itself after UNIX.

>> No.2607088

>>2607079
WRONG

C was designed FOR USE WITH UNIX, not to program UNIX. ASM was the primary language of choice for programming UNIX.

>> No.2607091

>>2607079
not the original one

>> No.2607096

>>2606989

You slipped up, Java boy. There is no Lisp, is there.

>> No.2607107
File: 28 KB, 424x432, 1298236848868.jpg [View same] [iqdb] [saucenao] [google]
2607107

Your mods are fucking retarded. Fucking banned me for no reason (which i don't really care about because i work for the isp and can get a new ip address in seconds) what what really grinds my gears is the derp fuck deleted all my posts. What the hell kinda retard is moderating this shit and fucking up the flow of the board as you can see from all the greened out links clearly I was an key part of the conversation.

I wish i could reach through the internet and clean the gene pool by strangling that bastard!

>> No.2607135

>>2607107
work safe board
probably because of that baby head

>> No.2607148

>>2607107

Get revenge, since you work for the ISP blacklist 4chan to all your customers.

Put a dent in moot's ad revenue and the mods will get a cluebat pretty quickly.

>> No.2607156

fucking mod just because you lack the abilaty to compehend something dose not make it incompehinsable

>> No.2607155 [DELETED] 
File: 93 KB, 600x339, spad_moderator.jpg [View same] [iqdb] [saucenao] [google]
2607155

>>2607107

Due to the new influx of janitors, modfaggotry has been at an all time high recently. See also moot's faggy autob&ing of anyone who uses the joo-word or the n1gur-word on any blue board.

Hopefully it'll go back to normal soon.

>> No.2607160

>>2607058
>>2607079
>>2607088
Really, last I heard, C was basically invented by a single guy at Bell labs /just to program Unix/, as he deemed other existing programming languages insufficient for the task.

>> No.2607161

chemist (purifies the silicon, germanium, phosphorous, etc used to make the chips)

physicist - designs the physical structure of the chip

ME or EE - builds the chip using the chemicals from the chemist and according to the standards set up by the physicist.

ME - builds the fabrication toolds (MOCVD, PD, MBE, etc apparatii)

CE (computer engineer), EE - builds/designs the circuits

CE (computer engineer) - does basic mathematics, and theoretical computer science to construct statistical engines and other "basic" lowest-level "programming" of the hardware

CS - builds up from functioning hardware to top level software...

does everything from the compiler to the kernel, but nothing requiring significant insight into the mathematics or physics of the hardware itself.
note:


chemical engineers do not know enough chemistry to design a inorganic purification system (electrochemical or chemical, involving high temps, pressures, Chlorine, fluorine, phosphine, SiCl4, and other extremely nasty chemicals)...

Chemical engineers do not know enough physics or mathematics or electronics to replace anyone else.


Chemical engineers CAN, however, tell you exactly how much of Chemical #1 should be pumped into a container with Chemical #2 to ensure maximum reaction rates.


that is what chemical engineers know: thermodynamics and kinetics.


how to mix shit up best.

>> No.2607164

>>2607155
Wait, did he announce new janitors?

>> No.2607172

>>2607160

>Although C was designed for implementing system software, it is also widely used for developing portable application software.

UNIX was programmed in ASM. C was used for modular support.

/programming since 1981

>> No.2607175

srsly mod its not like he was posting magnets or cp

>> No.2607180

>>2607160

>/just to REprogram Unix/

Nice try though. You almost convinced us you know the history of your field.

>> No.2607184

>>2607172
Mmm, it seems that the real history isn't that simple.
http://www.livinginternet.com/i/iw_unix_c.htm
http://en.wikipedia.org/wiki/C_%28programming_language%29

>>2607180
My mistake.

>> No.2607192

>>2607164
He was never going to "announce" them, I don't think.

Lol I just noticed I got b& on my other computer (diff network) for posting in the furry thread. This is getting out of hand lol.

Oh well, hooray for dynamic IPs.

>> No.2607197

Well we can start a huge thread on /sci/ demanding removal of the janitor/mod responsible.

Or flood moot's e-mail and AIM.

But blacklisting 4chan on the ISP-side is much more lulzy.

>>2607184
>The origin of C is closely tied to the development of the Unix operating system, originally implemented in assembly language on a PDP-7 by Ritchie and Thompson, incorporating several ideas from colleagues. Eventually they decided to port the operating system to a PDP-11. B's inability to take advantage of some of the PDP-11's features, notably byte addressability, led to the development of an early version of C.

Again, UNIX was done in ASM. C was created for modular support, because the B was incompatible with some of the PDP-11.

Exactly what i said earlier, there's nothing deeper than that.

>> No.2607203

>>2607197
Indeed, I think I was largely capitulating.

>> No.2607214

>>2607197
>>2607192
why should we complain about mods doing their job?

and Unix is not the first OS

>> No.2607215

>>2607175

violating rules like homework, or posting homework or porn wont get you banned but adding to a discussion cleqarly will

wtf man

>> No.2607225

>>2607214
Complaining about bans? That's a banning.

>>2607215
I lol'd when the mod who banned me and wiped out my posts also wiped out a full, worked out solution to a problem I wrote in another thread (which didn't seem to be h/w, but even if it was, whatever).

>> No.2607239

>>2607214
doing there jobs and inforcing ruels is one thing
banning peple without clear reson s another
also you are probably the fucking mod now go and die

>> No.2607262

>>2607214

They're doing it IMPROPERLY.

Even a blind person can see that.

>> No.2607276

>>2607262

The rules are vague enough (for instance: 'trolling' and 'going off topic' are against the rules everywhere except /b/) that mods can pretty much ban whoever they want and find a justification for it.

>> No.2607277

Everything is built on 1s and 0s. Work your way up from there.

>> No.2607297

>>2607239
i'm not the mod but i'll die too in 50 years or so..

>>2607225
>>2607262
>>2607239
don't you see /sci/ is shit
religion, homework and other troll shit is what i see on /sci/
this is not /b/
and wtf furry thread...

that's why lately i've been posting more on other boards...
/sci/ sure is getting worse and someone has to do something about it..

>> No.2607344

>>2606948
>>2606975
>>2606979
samefag

0/10

>> No.2607360
File: 2.01 MB, 3264x2448, DSCN0009.jpg [View same] [iqdb] [saucenao] [google]
2607360

I once put together a toy CPU out of simple ICs such as logic gates, flip-flops, and shift registers. Bought some more complicated chips for the memory, though. The initial programming was via the switches. Eventually I got a keyboard interface working.

>> No.2607366

>>2607297
>/sci/ sure is getting worse and someone has to do something about it..

/sci/ has been around for a few months and was never any good. There might be a half dozen people here with any serious (i.e. postgraduate) knowledge of science or math, so what can you realistically expect besides homework, troll science, and science v. religion threads?

Given that the furry thread was about the feasibility of genetically engineering furries IRL, it was actually one of the more "sciency" threads here. But now it's gone.

>> No.2607369

An assembler was written in machine code. And thus life was born, beyond that I refer you to Origin of Species.

>> No.2607378
File: 46 KB, 446x388, s19798_mfw.jpg [View same] [iqdb] [saucenao] [google]
2607378

>>2607360
mfw you could've just bought a real computer instead at a much cheaper price

>> No.2607560
File: 7 KB, 191x234, lovely-wow.png [View same] [iqdb] [saucenao] [google]
2607560

>>2607360

>> No.2607570
File: 56 KB, 500x512, 1273822720794.jpg [View same] [iqdb] [saucenao] [google]
2607570

>>2607360
Grandson, I am pride

>> No.2607601

>>2607360

Can't you just do that on a software simulator and save yourself a shitload of welding or w/e?

We basically did that (design a limited-functionality processor and write basic programs for it) as the final project for a sophomore CS class I took last year. The software package started with 'Q', IIRC, but I can't think of the name...

>> No.2607610

>>2607601
I don't mean "software simulator". idk what it was called

>> No.2607711

>>2607601
Those are solderless breadboards. All the connections are made by cutting wires and plugging them into the holes. No "welding" required.

>> No.2607733

Start with rock computer