This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes General Computing and the fly likes Techniques vs Languages Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Techniques vs Languages" Watch "Techniques vs Languages" New topic
Author

Techniques vs Languages

Rubbal Bhusri
Ranch Hand

Joined: Dec 30, 2010
Posts: 71
Which of these, either techniques or Languages came first ?
By techniques, I mean, sorting techniques such as selection sort, bubble sort, binary sort, merge sort, heap sort, quick sort etc.
and searching techniques like binary search, depth first search, prims algorithm, kruskal's algorithm etc.

If techniques existed before the adment of these languages then My question is that, do these languages are designed keeping in mind ways to implement these techniques or by co-incidence they happen to implement these techniques also ??
My second question is that, Do all languages that exists till today can implement all these kind of existing techninques of sorting , searching etc. ??
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 4531
    
    5

Since this isn't about Java, I've moved it here from the Beginning Java section.


luck, db
There are no new questions, but there may be new answers.
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 3616
    
  14

The two don't really rely on each other. They can be developed and exist independently from each other. Languages are not designed with these specific techniques in mind, because any machine capable of moving data around and doing basic arithmetic can perform these techniques.
Kemal Sokolovic
Bartender

Joined: Jun 19, 2010
Posts: 825
    
    5

Which of these, either techniques or Languages came first ?
By techniques, I mean, sorting techniques such as selection sort, bubble sort, binary sort, merge sort, heap sort, quick sort etc.
and searching techniques like binary search, depth first search, prims algorithm, kruskal's algorithm etc.

If techniques existed before the adment of these languages then My question is that, do these languages are designed keeping in mind ways to implement these techniques or by co-incidence they happen to implement these techniques also ??

Those that you refer to as techniques are actually specific algorithms. And yes, by my opinion, they come before computer programs (hence, languages) and even computers in general. Just consider Euclidean algorithm (known even 300 years b.c.). Programs (and programming languages that enable their creation) just provide the ability for machine to execute it, so they are not so tightly bounded.

My second question is that, Do all languages that exists till today can implement all these kind of existing techninques of sorting , searching etc. ??

Yes if the specific language is Turing complete


The quieter you are, the more you are able to hear.
Rubbal Bhusri
Ranch Hand

Joined: Dec 30, 2010
Posts: 71
then What purpose keeping in mind these languages are designed ??
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14117
    
  16

Many programming languages are general-purpose programming languages. That means they were not designed with a particular purpose in mind - they were invented to be useful for many different applications.

You could compare it to human languages. Your native language was not invented so that people could talk about one particular subject. Instead, you can use your language to talk about whatever subject you're interested in.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38515
    
  23
But many languages were designed with a specific purpose intended. For example, SQL is designed for querying databases and HTML is designed for displaying text, images, etc on a website. They are both good for what they do, but you can’t use SQL on a website, nor HTML on a database.
And I believe neither HTML nor SQL is Turing complete.
Ivan Jozsef Balazs
Rancher

Joined: May 22, 2012
Posts: 867
    
    5
Campbell Ritchie wrote:But many languages were designed with a specific purpose intended.


For example a design criterium for the language COBOL (COmmon Business-Oriented Language) was that the code resembles English sentences.


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

Verbose syntax

COBOL syntax has often been criticized for its verbosity. However, proponents note that this was intentional in the language design, and many consider it one of COBOL's strengths. One of the design goals of COBOL was that non-programmers—managers, supervisors, and users—could read and understand the code. This is why COBOL has an English-like syntax and structural elements—including: nouns, verbs, clauses, sentences, sections, and divisions. Consequently, COBOL is considered by at least one source to be "The most readable, understandable and self-documenting programming language in use today. [...] Not only does this readability generally assist the maintenance process but the older a program gets the more valuable this readability becomes."[10] On the other hand, the mere ability to read and understand a few lines of COBOL code does not grant to an executive or end user the experience and knowledge needed to design, build, and maintain large software systems.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Techniques vs Languages