Software Design
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreSoftware Design

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 10th, 2005, 04:47 PM
zapata zapata is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2003
Posts: 96 zapata User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 19 h 36 m 16 sec
Reputation Power: 6
Paradigm changes (From Java to Lisp)

Hello

there are lots of languages in the programming field, like Java, C, PHP, C++, Objective C, Ruby, and so on.

Altough some these language s don't share the same paradigm (example: C is imperative, JAVA is OO), they have lot's of things in comon - constructs - and, in example, it's possible to write non-OOP code in Java wich will look like procedural code).

Now let's say one needs to do a paradigm change and go from a language like Java to a language like Lisp. This will imply a new way of thinking about programming.

The point of this thread is to gatter some experiences with these "harder" paradigm changes - not necessarly with those languages. So, what's yours? Was it "hard", was it pointless and you ran away screaming, was it good for your general programming skill?

The reason for the interest: one of my courses this semestrer is a ADT course with the lisp language so I want to get some pointers on this so I don't get caugth in the paradigm.

Any other advice is welcome.

Thanks

Reply With Quote
  #2  
Old October 11th, 2005, 06:36 AM
dalyboy dalyboy is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 27 dalyboy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 26 m
Reputation Power: 0
Hi zapata,

This is an interesting topic to discuss. I myself have have programmed in LISP in the past and other languages such as JAVA, C, PASCAL and VB. I'm not an expert in any, but I know how to program, so personally the language doesn't bother me too much.

Personally from my experience I think LISP is good fun & very useful learn, it's a functional language based on symbolic representation and the manipulation of these symbols - which means everything is a function and thus the syntax reflects this (loads of brackets...and I mean loads) so programs can be built in a very efficient way, you define 'inner'-functions, then 'outer' functions which call the inner ones and keep doing this till you have something productive.

I was a bit daunted by it at first, but as I actually learnt LISP before I did JAVA, I think it has helped me build more efficient functions and methods for whenever I program.

I think it's defonately useful as it will help you understand more obscure languages and general logic if ever you have read them whilst in the industry, you wil feel more comfortable so it's only a good thing.

Finally programming should never be considered 'hard', its just about communicating in a restricted way. Speaking/writing english is actually more difficult. If your programs work in theory, they will work when put into code, If they don't, the theory must be wrong!

Good luck with you're course

Dalyboy

Reply With Quote
  #3  
Old October 12th, 2005, 10:14 AM
jamieB jamieB is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Nov 2002
Posts: 596 jamieB User rank is Sergeant (500 - 2000 Reputation Level)jamieB User rank is Sergeant (500 - 2000 Reputation Level)jamieB User rank is Sergeant (500 - 2000 Reputation Level)jamieB User rank is Sergeant (500 - 2000 Reputation Level)jamieB User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 2 Days 3 h 19 m 33 sec
Reputation Power: 18
I have recently been learning common lisp after having had a fair amount of experience with ALGOL family languages (eg java) so I know where you're coming from. It can be slightly frustrating and you may feel (as someone said on c.l.l recently) that you're going from being a doctor or a lawyer in your own language (one you've mastered) to being a taxi-driver in someone else's. But as you say, it's really a great thing to do - even if you're may be unlikely to produce production lisp code, it will teach you things about programming, programming languages, data structures, algorithms and so on. It's really a delight to use and even as a stumbling newbie I can get ideas down in code surprisingly quickly, using very little code.

My experience is that the way it looks - the prefix notation and the brackets, even the striking lack of boiler-plate code and syntax - isn't a problem. This just melts away very quickly and you're left looking at the code, especially if you use SLIME/emacs, which takes care of brackets/indentation etc. What is more challenging are things like macros, which don't seem to have an equivalent in other languages, lexical closures, lots of lambda functions and functions that take lambdas as parameters etc, which are possible in many languages but not normally as widely used...this is still stretching my brain! Although they might be puzzling at first, these are obviously very elegant, powerful ideas that will appeal to anyone interested in programming.

The main thing to note about lisp from the p.o.v of paradigms is that it doesn't have one built in. If anything, the programmer imposes a paradigm onto it. It's an inherently flexible language that you can use to write in any style which may or may not be what people normally think of as 'lispy' - procedural, functional, OOP, create your own embedded language if that's more convenient. To take OOP, in common lisp you have CLOS, or if you're using a lisp that doesn't have objects you can write objects into it using 50 or 100 lines of code (this is done as an example in the paul graham book below).

If you haven't already, have a look at practical common lisp. Other good reads are ANSI Common Lisp by paul graham and, of course, the wizard book.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreSoftware Design > Paradigm changes (From Java to Lisp)


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT