Unix and Programming Languages

A place where newbies can post without (much) fear of reprisal. All mission posts should still go in the applicable forum.
Forum rules
Older HTS users: Be nice to the new people.

NEW USERS: This is NOT the place to post about missions! Refer to "Missions" category.

Unix and Programming Languages

Post by thehackertoyou on Thu Jan 31, 2013 4:10 pm
([msg=73076]see Unix and Programming Languages[/msg])

Hi all! I'm pretty new to HTS, but I'm really excited to get going! I'm guessing that the answers I'm looking for are somewhere on here already but I don't feel like looking through 50+ pages of a forum... =0
Anyway, I was wondering, I think I have a pretty good Idea of what I need to do on mission 7, (type a unix command into Sam's script so it will show me the password file) but I just wanted to know a few things first. What is Unix? I'm guessing it's a programming language but what is it used for, and how (generally) does it operate and what are a few good commands to start with? That brings me to another question I've been wondering a lot recently, but where is a programming language used? Is it like a computer reads a certain language, a website reads a certain language, a program, all of the above? Or does it depend on wich programming language it is? Thanks in advance guys. :D
thehackertoyou
New User
New User
 
Posts: 18
Joined: Tue Jan 01, 2013 1:27 pm
Blog: View Blog (0)


Re: Unix and Programming Languages

Post by limdis on Thu Jan 31, 2013 4:32 pm
([msg=73078]see Re: Unix and Programming Languages[/msg])

I broke this out of the Basic Mission 7 thread because you asked a few questions that are separate from the challenge and are in and of themselves large discussion topics.
"The quieter you become, the more you are able to hear..."
"Drink all the booze, hack all the things."
User avatar
limdis
Moderator
Moderator
 
Posts: 1414
Joined: Mon Jun 28, 2010 5:45 pm
Blog: View Blog (0)


Re: Unix and Programming Languages

Post by LoGiCaL__ on Thu Jan 31, 2013 5:54 pm
([msg=73085]see Re: Unix and Programming Languages[/msg])

Unix is not a programming language it is a Operating system.

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

Also check out Linux.
User avatar
LoGiCaL__
Addict
Addict
 
Posts: 1063
Joined: Sun May 30, 2010 12:33 pm
Blog: View Blog (0)


Re: Unix and Programming Languages

Post by centip3de on Thu Jan 31, 2013 7:11 pm
([msg=73088]see Re: Unix and Programming Languages[/msg])

thehackertoyou wrote:Hi all! I'm pretty new to HTS, but I'm really excited to get going! I'm guessing that the answers I'm looking for are somewhere on here already but I don't feel like looking through 50+ pages of a forum... =0
Anyway, I was wondering, I think I have a pretty good Idea of what I need to do on mission 7, (type a unix command into Sam's script so it will show me the password file) but I just wanted to know a few things first. What is Unix? I'm guessing it's a programming language but what is it used for, and how (generally) does it operate and what are a few good commands to start with? That brings me to another question I've been wondering a lot recently, but where is a programming language used? Is it like a computer reads a certain language, a website reads a certain language, a program, all of the above? Or does it depend on wich programming language it is? Thanks in advance guys. :D


Unix is an operating system, much like Microsoft Widows is. This operating system is what (I think) Mac OS X runs as it's kernel (the brain of the operating system). Because Unix cost quite the pretty penny, back in the 80's a guy called Linus Torvalds wrote a clone of Unix called Linux. This operating system is what either the majority of the people here run, dual boot, or at least have experience with. If you want to get that experience for yourself, download a virtual machine (VirtualBox), a version of Linux (Ubuntu) and try it out for yourself!

Also, a programming language is ALWAYS run on the computer. It may not be your computer, it may be a server somewhere else, but it ALWAYS runs a on a computer. Computers themselves are essentially a bunch of On/Off switches, similar to those that you use to turn on a light... except that this switch is controlled by the flow of electricity, (no electricity = off, electricity = on) instead of a finger, and that they're microscopically small. However, unless you want to manually turn on every single switch that's required to display an image (approximately 2895600 of them), you need something to do it for you. This something is what is known as binary. You know, those 1's and 0's you see in all the fake TV shows? Yeah, that. A 1 represents power to the switch, and a 0 represents off. Hurray! You can do it automatically... sort of. You still have a problem, though; you need to write either a 1 or a 0 for each switch you want, which is hardly easier than switching them yourself.

Because people are lazy, we invented another language called Machine Language. This language is MUCH easier than writing in pure binary, as it allows you to name variables, place variables in certain parts of the computer, and just generally be a badass. The downside to this language is that it is, as the name implies, not very human-friendly, and as such is hard to write in. Thus, even lazier people developed a language called assembly language. This makes machine language human friendly, and still is WAY easier than writing in binary. The only down side to it, is it's still about just as time consuming as writing in machine language. People wanted something that they can write fast, instead of it taking maybe a day or two, to get a simple program working. And, as we've learned, programmers are lazy, and so they just kept inventing easier, and easier languages until we have the ones we do today.

Don't be confused, though, the computer itself never changed what it reads (binary). But because we are now developing in such easy (high-level) languages, they have to be translated into binary somehow, no? Well, there's two things that do that; one, something called a "compiler" that turns whatever language you've written into assembly language (remember it's that thing that was just a step above machine language). Then, a thing called an "assembler" turns that assembly-language into machine language, and then your processor (CPU (the brain of the computer)) turns that into binary, all by itself. This process happens inside every computer, in every language, constantly. You think that HTML that you're writing will be run in the web browser? Nope. The web browser is being run by the computer, so, the HTML is indirectly being run by the computer. Hope that helps clarify some things.

TL;DR:
Just read the damn post.
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. -Rick Cook
User avatar
centip3de
Moderator
Moderator
 
Posts: 1449
Joined: Fri Aug 20, 2010 5:46 pm
Blog: View Blog (0)


Re: Unix and Programming Languages

Post by thehackertoyou on Tue Feb 05, 2013 9:44 pm
([msg=73497]see Re: Unix and Programming Languages[/msg])

Ooohh, ok. so now I have a few more questions. (I'm learning!) first, what is a kernel? second, if mac uses unix, and I am on a mac, then is there some way I could get behind the user-friendly interface and into the unix code so that I can interact with the computer directly through unix commands? and third, if unix is an os, how does mission 7 read unix? Idk if that makes any sense, but I mean how does the website accept unix commands? (BTW I already beat mission 7)

-- Tue Feb 05, 2013 7:50 pm --

oh wait, re-reading the last post I think it makes sense. an os operates the computer, and all programming languages are processed by a computer, but not necessarily my computer. so when I type unix commands into the site for mission 7 it sends that code to a different computer, which is probably using unix, and then that computer sends the output of the unix cal command and sends it back to me? I think?
thehackertoyou
New User
New User
 
Posts: 18
Joined: Tue Jan 01, 2013 1:27 pm
Blog: View Blog (0)


Re: Unix and Programming Languages

Post by centip3de on Tue Feb 05, 2013 11:03 pm
([msg=73505]see Re: Unix and Programming Languages[/msg])

thehackertoyou wrote:-- Tue Feb 05, 2013 7:50 pm --

oh wait, re-reading the last post I think it makes sense. an os operates the computer, and all programming languages are processed by a computer, but not necessarily my computer. so when I type unix commands into the site for mission 7 it sends that code to a different computer, which is probably using unix, and then that computer sends the output of the unix cal command and sends it back to me? I think?


Well, in this case, it's something just pretending to be a Unix Operating System, but essentially yes, you are correct.
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. -Rick Cook
User avatar
centip3de
Moderator
Moderator
 
Posts: 1449
Joined: Fri Aug 20, 2010 5:46 pm
Blog: View Blog (0)



Return to NZone

Who is online

Users browsing this forum: No registered users and 0 guests