general question?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting general question?
# 1  
Old 12-17-2003
general question?

Perl, Python, and PHP are these languages easy to use? Are they command line or are they part of a GUI?
# 2  
Old 12-17-2003
Well, easy for some to use, not so easy for others!! I realize this is probably not the answer you are looking for but it is close to truth Smilie

Out of Python, Perl, and PHP - In my opinion I think that PHP is probably the easiest, then Perl, then Python. PHP is a server side scripting language for web pages. Python is both GUI and command line. Perl is command line and is commonly used for a host of tasks.

If you were going to begin learning one of these languages,
I would suggest that you learn Perl. You will get more mileage
from it! As a start, take a look at a smaller language such as Awk to get your feet wet.

Happy coding.

PHP Link
Perl Link
Python Link

Code:
Python
Python is a clear and powerful object-oriented programming 
language, comparable to Perl, Tcl, Scheme, or Java.

Some of Python's notable features:

Python uses an elegant syntax for readable programs. 

Python is an agile language that makes it easy to get your 
program working. This makes Python an ideal language for 
prototype development and other ad-hoc programming tasks, 
without compromising maintainability. 

A variety of basic data types are available: numbers (integers, 
floating point, complex, and unlimited-length long integers), 
strings (both ASCII and Unicode), lists, dictionaries. 
Python supports object-oriented programming with classes and 
multiple inheritance. 

Code can be grouped into modules and packages. 

The language supports raising and catching exceptions, resulting 
in cleaner error handling. 

Data types are strongly but dynamically typed. Mixing 
incompatible types (e.g. attempting to add a string and a 
number) causes an exception to be raised. 

Python contains advanced programming features such as 
generators and list comprehensions. 

Automatic garbage collection frees you from the hassles of 
memory management. 

The large standard library supports many common programming 
tasks such as connecting to web servers, regular expressions, 
and file handling. 

Python's interactive mode makes it easy to test short snippets of 
code. There's also a bundled development environment called 
IDLE. 

The Python interpreter is easily extended by adding new modules 
implemented in a compiled language such as C or C++. 
The interpreter can also be embedded into an application to 
provide a programmable interface. 

Python runs on many different computers and operating systems: 
Windows, MacOS, many brands of Unix, OS/2, ... 

Python is copyrighted but placed under an open source license, 
meaning that Python can be freely used and distributed, even for 
commercial purposes. 

PHP
PHP is a widely-used general-purpose scripting language that is
especially suited for Web development and can be embedded 
into HTML.

Perl - Pathologically Eclectic Rubbish Lister 
Perl is a high-level programming language with an eclectic 
heritage written by Larry Wall and a cast of thousands. It derives 
from the ubiquitous C programming language and to a lesser 
extent from sed, awk, the Unix shell, and at least a dozen other 
tools and languages. Perl's process, file, and text manipulation 
facilities make it particularly well-suited for tasks involving quick 
prototyping, system utilities, software tools, system management 
tasks, database access, graphical programming, networking, and 
world wide Web Development. These strengths make it especially 
popular with system administrators and CGI script authors, but 
mathematicians, geneticists, journalists, and even managers also 
use Perl. Maybe you should, too.


Last edited by google; 12-18-2003 at 12:06 AM..
# 3  
Old 12-18-2003
Perl can also do GUI programming, but this is not most Perl programmers are going to use (possibly people would prefer TCL or Java/C instead for this purpose).

I'm pretty familiar with Perl, but I find it a lot easier to handle compared with shell scripting and awk/sed etc., possibly because I came from a programming background instead of a sysadmin background. So I personally do not agree that awk/sed can be used to get my feet wet. To me, shell scripting seems to get my hands really "dirty" that I would try to avoid shell scripting wherever possible (unless the task demands it).

PHP may not be necessarily easier than Perl. It totally depends on what you are trying to learn (and do). PHP is most suited for Web server-side scripting, however.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Programming

General question about learning Python

I am planning on taking a class in Python. My choices are 2.5 or 3.0. Which version should I choose? I am getting the impression they are two separate paths. thanks. (5 Replies)
Discussion started by: djehresmann
5 Replies

2. Shell Programming and Scripting

General question about passing variables among shell scripts

So this is something I've been wondering how to do for a while. Suppose I have two shell scripts a.sh and b.sh script a does some function and outputs to a varable $x . I would then like to take $x into the second function, b.sh, and do a function on it and create some output. So how do you pass... (3 Replies)
Discussion started by: viored
3 Replies

3. UNIX for Dummies Questions & Answers

General question about folder level permissions

How is the level of access on a particular folder determined? I have heard (its just hearsay so am not particularly sure of it) that the access a particular user/group has to a low level directory is also affected by the level of access granted to the user/group on its parent directories. e.g. ... (1 Reply)
Discussion started by: jawsnnn
1 Replies

4. Linux

General compression question

I am looking for an alternate solution other than gzip or bzip2 to compress files that are 3 to 4 GB each and will be hundreds per day. Aside from increasing storage anybody found a good tool? (5 Replies)
Discussion started by: mykey242
5 Replies

5. Solaris

General question about configuring DHCP on Solaris

Dears, my question is that possible to configure any server to work in solaris zone i mean any server cos i read that DHCP can't be work on solaris zone is that real or not Best Regards Alexander Corvinus (4 Replies)
Discussion started by: corvinusbsd
4 Replies

6. UNIX for Dummies Questions & Answers

General Programming Question

Experience level : New to programming in Linux. Forgive my noobiness in this context with regards to programming, language or grammar. Some Background info : I have seen a lot of programs which I use (Modo and Maya especially) which can use a command line to run the different parts of the... (2 Replies)
Discussion started by: snd321
2 Replies

7. UNIX for Dummies Questions & Answers

Executable directory general question

This may be a dumb question (but this is the UNIX for Dummies Q&A forum :) But I'm wondering, what is the purpose of a directory being given execute permissions? I can't execute a directory, only files, right? If I make a directory executable, the files inside still won't execute unless I give... (1 Reply)
Discussion started by: FredSmith
1 Replies

8. UNIX for Dummies Questions & Answers

General Question

Hi, I've been racking my brains trying to remember, but, whats the command to change the default shell? I'm currently always in the Korn shell and I want to start out in the Bash shell. I'm running a variant of BSD I guess in Mac OS X 10.2.2 and Mandrake. Thanks. ccindyderek:confused: (4 Replies)
Discussion started by: ccindyderek
4 Replies

9. UNIX for Dummies Questions & Answers

General Proxy Question

This is quite a general question: I am trying to detect whether people accessing my network are using a proxy server. This is *not* to ensure that web pages are not cached! The only way that I can think of doing this is to intercept at packet level and examine the source port for... (1 Reply)
Discussion started by: sam_pointer
1 Replies

10. IP Networking

General Proxy Question

Firstly I must apologise; I have posted something similar in the "general UNIX newbies" forum; but in reterospect I think that it's more appropriate here. Anyhoo; I am trying to detect whether people accessing one of my servers are coming via a proxied connection. I must add that this is... (1 Reply)
Discussion started by: sam_pointer
1 Replies
Login or Register to Ask a Question