?
Solved

Programming Languages on Operating Systems

Posted on 2003-03-09
15
Medium Priority
?
279 Views
Last Modified: 2010-04-17
Is there a programming language that does not rely on a certain operating system being used? (eg one which is truly mulit platform/os independant??)

If so .. which one?


Cheers (Frosty)
0
Comment
Question by:frosty12345
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
  • 2
  • +4
15 Comments
 
LVL 41

Expert Comment

by:stevenlewis
ID: 8097912
I beleive java, as long as there is a JVM (java virtual machine) installed then the JVM translates for the OS
0
 
LVL 1

Expert Comment

by:yabelson
ID: 8097914
that depends on what exactly you need it to do...
and what os's you need it to work with - if its only Microsoft based ,or Macs as well...
0
 

Author Comment

by:frosty12345
ID: 8098011
ANY os mac, freebsd, linux everything.
0
Get proactive database performance tuning online

At Percona’s web store you can order full Percona Database Performance Audit in minutes. Find out the health of your database, and how to improve it. Pay online with a credit card. Improve your database performance now!

 
LVL 41

Expert Comment

by:stevenlewis
ID: 8098022
well Java runs on all of them mac, linux, M$. If the OS supports Java (has a JVM), it will run
0
 

Author Comment

by:frosty12345
ID: 8098040
is that the only language?

are there any major os's that dont support java (or JVM)?
0
 
LVL 41

Expert Comment

by:stevenlewis
ID: 8098057
some of the programming experts may have more info on this than I do, but as far as I know all major OS's (except maybe DOS, and that wouldn't be considered major any more) support it.
0
 

Author Comment

by:frosty12345
ID: 8098076
ok good can Java be compiled to a .exe format?  Im not a techie but i have only ever seen java embedded in webpages (to my recollection)

Can it be used seperatly?
0
 
LVL 41

Expert Comment

by:stevenlewis
ID: 8098092
They have java office suites, etc
see www.sun.com for more info on java
BTW java doesn't compile to an exe (linux and MAC's don't use exe's)
0
 

Author Comment

by:frosty12345
ID: 8098104
can it be compiled into a style like a .exe?
0
 
LVL 41

Expert Comment

by:stevenlewis
ID: 8098118
Yes, it does compile into a format, but I'm not sure what it is (I'm not a programmer) I think it's a .jar file, again I'm not sure
0
 
LVL 2

Expert Comment

by:antonsigur
ID: 8098124
Java must run on JVM - so no java virtual machine - not runnable.

You could write your program in c++.

Then again, you must recompile it for every OS you want to run it on.

You may get in trouble - Oses uses diffrent operating system calls, so you must be careful or implement að "interface" wich you change when compliling for another os.

I will recomend using Java, it's portable and you don't need to compile it for every OS.

When you write Java source, and compile it, it will not fully compile, it will compile to byte code, wich the java virtual machine will read and run on the os.

Read som java tutorals on the net to learn more.

0
 
LVL 7

Expert Comment

by:billious
ID: 8100602
Every language has its strengths & weaknesses. Each was designed with a specific task in mind.

Each hardware platform has a unique instruction set, so a compiled object file will only run on the harware for which it was designed.

The purpose of a high-level language is to make the program OS- and architecture-independent, and use the OS-specific compiler to generate code to suit the final environment.

Having said that, compiler-constructors then ofter extend the language to include facilities that are available in the destination environment. This makes the compiler more salabe than a plain-vanilla variety. As a simple example, you can't use long filenames on DOS or OS/360 systems, since long filenames are not available on those systems, but you can't leave them out of *nix systems, since they're a fundamental concept to those OSs.

It is possible to construct a 'p-code' compiler for virtually any language, which produces a file that can be transported directly from platform to platform. You then need a matching P-code interpreter to execute the file. This has its uses, but is still subject to the restraints of the OS, obviously.

Java is very net-oriented, and does that job well. I have seen some valiant efforts to make it work as a general-purpose commercial language, but I feel it really doesn't make the grade on mainframe systems, for instance.

I'd suggest C to be one of the most common languages available for most platforms. C++, then you take your chances (but have more facilities for use in the platform-set you choose...)

Think of it this way - If you were to try to get a universal tool, would you choose a hammer, a screwdriver or a spoon?

...Bill
0
 
LVL 2

Accepted Solution

by:
nir2002 earned 60 total points
ID: 8101949
Hi,

the best choice is JAVA is the only general porpuse language that is portable.
You can use it eithr to create Applet or Serlvet(as net language) or to create standalone application with her.
As mention above you need a JVM for compile & interpter the byte code (virtual machine code) into the specfic mechine language and execute it.

There are tools that convert the .class file to .exe but by doing that JAVA will lose her portablity advantage.

Best regards
Nir
0
 
LVL 1

Expert Comment

by:yabelson
ID: 8126726
NIR - from Israel?
where from?- im from B.S.
0
 

Expert Comment

by:CleanupPing
ID: 9447248
frosty12345:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Computer science students often experience many of the same frustrations when going through their engineering courses. This article presents seven tips I found useful when completing a bachelors and masters degree in computing which I believe may he…
Q&A with Course Creator, Mark Lassoff, on the importance of HTML5 in the career of a modern-day developer.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Progress
Suggested Courses

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question