Programming Languages
#1
Posted 07 April 2003 - 02:53 AM
I haven't done any programming in about 7 years, and that was with Turbo Pascal (6.x?) for DOS.
I am not initially interested in compiling anything for Linux, just Windows. However, it would be a nice feature if the language was either the same of similar on multiple platforms.
I will be recieving a free eval copy of Visual Studio .NET 2003 from the Windows Server 2003 launch event at the end of the month, and unless I am mistaken, that package will include C#, C++, Visual Basic, and J#. I think that I would like to learn one of these languages, and I have heard great things about C/C++, so that would probably be my starting point.
I don't really recall any of the language that I learned years ago, but I do recall some concepts, so hopefully the learning curve will not be too steep.
I know that Java/J# will probably be highly recommended, but I am curious to the future of the language, with the ongoing litigation between MSFT and Sun, and what impact that will have on the language. Also, while I'm asking about expected life expectancy of the languages, I would like any input on other programming languages life expectancy as well.
#2
Posted 07 April 2003 - 03:11 AM
It's cross-platform (latest edition for Windows is Delphi 7 and for Linux there's Kylix 3. Kylix has also C++ IDE, so you may just as well develope C++ applications) and you can get it for free from Borland's website.
Anyway, here're some free eBooks you might find useful:
Bruce Eckel's Free eBooks (Java, C++, C#)
Essential Pascal (Pascal)
Essential Delphi (Delphi)
Good luck!
#3
Posted 07 April 2003 - 10:02 AM
For those interested in C# who don't have VS.NET, I would recommend the free SharpDevelop IDE. They're still calling it a beta, but from what I've seen it's really solid...
#4
Posted 07 April 2003 - 01:38 PM
I've been looking into the DirectX9 SDK, using the Managed Code version looks far easier than through the COM interface...
All I need to do now is get to the Win2k3 launch for my copy of VS.NET 2k3...
Rgds
AndyF
#5
Posted 07 April 2003 - 05:07 PM
#6
Posted 07 April 2003 - 09:28 PM
I seriously think Java will win out over .NET. The main reason for this is taht Java is already being used and tought in the Academic world due to the fact that it is powerful, easy to use and most importantly, free. You can download several powerful, free Java IDEs for free. Most have the drag-and-drop style for building windows aps like VB started. As far as I know there is no .NET developer kit that is free of charge, thus I have never used .NET. To be fair though, I know very little about .NET software. I think the academic use of Java will give it the boost it needs, much like it did C in the early days.
#7
Posted 07 April 2003 - 11:10 PM
Look up JBuilder. Excellent program for building java applications/applets. Unlike what I have seen in Visual Basic however, these tools for java require that the programmer know something about the underlying code to set up event handlers. Its quick and easier to set up.
Thing is though, that alot of what you learn in academia does not really carry over in practice to the working world...
So, why do I say that you might be wondering.
Well, for me this is reaching back pretty far in time,around 1994 when I started working as a professional programmer!
I came out of MOSTLY a DOS/UNIX Operating System type, Assembler & C-C++ based background in school... w/ alot of Pascal & BASIC as well (other languages that I was taught like Fortran, & COBOL for instance, I have yet to use in the working world over a decade now).
I thought C was the best thing to happen to computers since sliced bread when compared to Assembler language @ least, & these two were my primary tools in academia @ least. They were decent to work with building character mode console apps in DOS/UNIX etc. but not so good for Windows apps I felt, VERY complex.
See, once I hit the working world however, BASIC was mostly everywhere though in VB/Access with "RAD" (rapid application development) tools & not in a DOS/UNIX character mode environs!
(First in Win16 code & shortly afterward, alot of porting it to Win9x OS' from Win3.x into Win32 code.)
The tools were VB & Access mostly for me (& later, linking that to backend servers like SQL Server, Oracle, & DB2), & it was a HUGE change from using DOS character mode tools that I liked in C/C++ & Assembler mostly, some Turbo Pascal!
I began to notice that for QUICK production, VB & Delphi were much better than building Information Systems @ least (the 'bread & butter' work out there for most programmers) & you could build working systems in 1/5th the time it would take in C/C++ in Windows @ least.
The point I guess I am trying to make is, that in academia, alot of professors & such are guys that may or may not have had actual out-in-the-working-world real world experience...
True some may have, some may have acted as consultants, but I would wager many have not.
So what they are teaching may or may not be in actual use out there... it may be good stuff, but the question is:
Does it prepare the student for the toolsets he may be confronted with out there in the real world?
* Most of what I got out of college @ least with dual degrees in this field, was principles... mostly.
Yes, the languages helped that I picked up on but by taking many of them by overloading my schedule, it was like taking diff. forms of martial arts I would guess as a sort of analogy... you started to see that what you can do in one, you can do in another (BUT, you have to know the questions first to ask from one language to another, thus what I meant about principles).
As far as teaching principles over specific languages goes, I think any respectable program teaches the concepts of programming as opposed to a language. However, you cannot teach the concepts without a language. In my experience, mosts institutions use C++ and Java. The fact that the folks coming out of school are familier with java is a huge incentive to use it because of familierity.
I agree completely. Java is not for Win32 application building. From my experience the performance is severely lacking, especially in the department of memory usage. Most of the Java IDEs are written in java and JBuilder would take over a minute to load on my XP1700 laptop. There are plusses and minuses to any language and like I said, I know very little about .NET. I don't see visual basic going away anytime soon either, nor should it. I am just making a case for Java.
#8
Posted 08 April 2003 - 12:34 AM
Actually, the .NET Framework SDK is free from Microsoft:
Microsoft .NET Framework Software Development Kit
It's just the IDE (Visual Studio) that they charge an arm and a leg for. Which is why I mentioned SharpDevelop, as it gives you a free IDE to go with the SDK.
#9
Posted 08 April 2003 - 01:03 AM
Open source... nice
Doesn't Delphi 7 ship with Delphi for .NET?? I believe it does.. hmmm.. if I recall it correctly.
#10
Posted 08 April 2003 - 07:04 PM
Actually, the .NET Framework SDK is free from Microsoft:
Microsoft .NET Framework Software Development Kit
It's just the IDE (Visual Studio) that they charge an arm and a leg for. Which is why I mentioned SharpDevelop, as it gives you a free IDE to go with the SDK.
Thanks! I'll try to remember to check this out in a couple of months when I have access to a decent connection.
#11
Posted 08 April 2003 - 08:05 PM
This is probably what you were thinking of: Mono. I haven't tried it, but it's a cool idea...
The Mono Project is an open development initiative sponsored by Ximian that is working to develop an open source, Unix version of the Microsoft .NET development platform. Its objective is to enable Unix developers to build and deploy cross-platform .NET Applications. The project will implement various technologies developed by Microsoft that have now been submitted to the ECMA for standardization.
Mono contains a number of components useful for building new software:[list][*]A Common Language Infrastructure (CLI) virtual machine that contains a class loader, Just-in-time compiler, and a garbage collecting runtime.
[*]A class library that can work with any language which works on the CLR.
[*]A compiler for the C# language. In the future we might work on other compilers that target the Common Language Runtime.
[/list:u]Windows has compilers that target the virtual machine from a number of languages: Managed C++, Java Script, Eiffel, Component Pascal, APL, Cobol, Perl, Python, Scheme, Smalltalk, Standard ML, Haskell, Mercury and Oberon.
The CLR and the Common Type System (CTS) enables applications and libraries to be written in a collection of different languages that target the byte code
This means for example that if you define a class to do algebraic manipulation in C#, that class can be reused from any other language that supports the CLI. You could create a class in C#, subclass it in C++ and instantiate it in an Eiffel program.
A single object system, threading system, class libraries, and garbage collection system can be shared across all these languages.
#12
Posted 08 April 2003 - 08:28 PM
#13
Posted 08 April 2003 - 09:31 PM
#15
Posted 08 April 2003 - 11:30 PM
Not exactly. From what I understand, there is a process in the VM that runs occasionally and deallocate any memory areas that are not connected with a pointer. I know for a fact that it is not instant. On several occasions, I have had to explicitly call the garbage collector.
Thanks for the info everyone!
I will probably mess around with C#, .NET and delphi as well this summer if time promitts.
#16
Posted 09 April 2003 - 12:19 AM
Java and .NET both have garbage collection, and while I was told that explicitly calling it in Java is a pain it's supposed to be a little easier in .NET, but still frowned upon just the same.
#17
Posted 09 April 2003 - 12:49 AM
#18
Posted 09 April 2003 - 03:15 AM
#19
Posted 09 April 2003 - 03:54 AM
This would actually be quite difficult (maybe impossible) to do reliably at compile time. Consider this (pseudo)code:
some_pointer CreateItem(int param1, float param2, ...) { PointerType ptr1, ptr2; ptr1 = malloc(sizeof(MyObject)); ptr2 = malloc(sizeof(MyObject)); (Do operations on ptr1 and ptr2) if ( test(ptr1,ptr2) ) return ptr1; else return ptr2; }
This may not be a good example of "real" code, but bear with me, I'm just illustrating a point. Here I really should have called free(...) on the pointer that wasn't returned, because it goes out of context. If the above "test" decided to return ptr1, then ptr2 should now be freed back to the heap. But it CAN'T free ptr1, because that will be used elsewhere. This being a simple example, maybe your extremely smart compiler could insert the correct free's right before my returns.
But then, how will it know when it's safe to free the other one? About the only way to do this is to insert a bunch of code in all your functions to keep track and check when that pointer can no longer be accessed. Only then is it safe to free. And all this extra code it threw in would basically be an implementation of garbage collection.
For lazy programmers (sorry, but that's the way I see it), garbage collection is nice to abstract yourself from memory allocation. But, there is definitely a performance penalty that comes with it. It is usually much more effective manage that yourself, because you can more easily find the opportune times to do the free's.
</preach>
#20
Posted 09 April 2003 - 04:13 AM
CUViper, I am in total agreement with you on garbage collection. I figured it was a lazy way to do things as well, and specifically asked how to destroy used objects. However, I was *strongly* advised (both in the text and in class/lab) not to adjust this behavior in Java or the results may not be what you expect. Not entirely encouraging, would you say?

Help










