Write a program to read the file, Programming Languages

Suppose you have a ?le orase of city and country names, like this:

Cluj, Romania
Debrecen, Hungary
Klagenfurt, Austria
Berlin, Germany
Szeged, Hungary
Budapest, Hungary
Lintz, Austria

Write a program towns.pl such that when it will read from the ?le orase will produce a sorted output with each country mentioned once, followed by an alphabetical list of the cities in that country:

Austria: Klagenfurt, Lintz.
Hungary: Budapest, Debrecen, Szeged.
Germany: Berlin.
Romania: Cluj.

Run your program against any other ?le (say, myfile) with structure similar to orase. Then execute your program against both ?les (orase and myfile) simultaneously.

Posted Date: 3/12/2013 1:44:44 AM | Location : United States







Related Discussions:- Write a program to read the file, Assignment Help, Ask Question on Write a program to read the file, Get Answer, Expert's Help, Write a program to read the file Discussions

Write discussion on Write a program to read the file
Your posts are moderated
Related Questions
For this assignment you will read a file expression.txt and create an expression tree. The expression will be a valid infix expression with the all the necessary parentheses so tha

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Software and sales assingment I keep get a syntax error

Expertsmind brings you unique solution in java assignments Interfaces A program in the Java selection language is a fuzzy type that is used to specify a program (in the ge

1.  Use mathematical induction to prove Whenever n is a positive integer. 2.  Use loop invariant to prove that the program for computing the sum of 1,...,n is correct.

I have a half done program that needs to be finished for a class by tomorrow night. The program will create a database and print out a menu ofoptions (already done). Ive already

how to store multidimensional array in a single column in mysql database using MATLAB?

a) Write a program i_language(Sentence,NewSentence) that translates a sentence to the i-language. In this language all vowels are changed to i and all other characters are kep


The software development team identified the following classes based on the analysis of given requirements: Product, Employee, ProductList, Supplier. 1.  Identify the relationsh