celieaoi92 0 Newbie Poster

How can i copy fileteks A to another fileteks?
fileteks A :
there are N kingdom.
each kingdom has a name of a string with no spaces and maximum of 8 characters.
each kingdom had fought each other as much as M times.
a historian has data on wars, year and each number of troops.
The winner has the most number of troops..
assume that the data contained on an island in a file, eg: island.txt

example of island.txt :

4
Brazil Italy Greek Singapore
3
1810 15 12 10 3
1900 3 4 1 7
1925 10 10 6 5


create a program to read files with the same format as above and resulted in the following islandout.txt:


Winner

======

year 1810 Brazil

year 1900 SIngapore

year 1925 Brazil and Italy

Jumlah selisih masing2 pasukan

==============================

1810 Brazil Italy Greek Singapore

Brazil 0 3 5 12

Italy _ 0 2 9

Greek _ _ 0 7

Singapore _ _ _ 0

1900 Brazil Italy Greek Singapore

Brazil 0 1 2 4

Italy _ 0 3 3

Greek _ _ 0 6

Singapore _ _ _ 0

1925 Brazil Italy Greek Singapore

Brazil 0 0 4 5

Italy _ 0 4 5

Greek _ _ 0 1

Singapore _ _ _ 0


please help me..
i'm confused where should i start.
just typed the file or i should insert it from pascal?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.