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
Develop a Windows Forms Application by creating a new project named "xxxxxxxx" in a new folder named "xxxxxxxxas3" where xxxxxxxx is your student id. You should delete file(s) with

Question: (a) Outline the six norms to be considered before designing a Web page. (b) Write a program such that when a user right-clicks anywhere on a Web page, the follow

I WANT TO MAKE PROJECT IN ARM LANGUAGE CAN YOU HELP ME

Given a list of numbers, say my @input_numbers = (1, 1, 3, 5, 8, 13, 21, 34, 55, 89, 144); write a program map1.pl that will use the function map (a) to produce a list of

In the form of hypermedia documents, Web pages or materials accessed by the Internet can be located anywhere in the world. Regardless of where they originated, most of the Web d

basic steps involved in spreadsheet developement

Explain what is HTML language with an example? HTML is the HyperText Markup Language. HTML files are text files featuring semantically tagged elements. HTML filenames are suff

One of the main strengths of the Perl programming language are its powerful text manipulation features. In this assignment, you will put them to use for writing a Perl program that

Determine the solution to the following differential equation. x 2 y′′ + 3xy′ + 4 y = 0   Solution Find the roots to (3) first as generally. r(r -1) + 3r + 4 = 0 r

Most popular news websites publish their RSS ( Really Simple Syndication ) feeds. If you haven 't heard of RSS, you may have a look at this article on Wikipedia. In this assignm