## Search found 14 matches

Tue Jan 27, 2004 9:42 pm
Forum: Volume 5 (500-599)
Topic: 524 - Prime Ring Problem
Replies: 74
Views: 19999
...why does my program get WA? [pascal] program primering; var x:array [1..1000] of integer; n:integer; visited:array [1..1000] of boolean; function prim(x:integer):boolean; var i:integer; begin prim:=true; for i:=2 to x div 2 do if x mod i =0 then begin prim:=false; break end; end; procedure writec...
Mon Jan 26, 2004 8:41 pm
Forum: Volume 5 (500-599)
Topic: 524 - Prime Ring Problem
Replies: 74
Views: 19999
"Each row represents a series of circle numbers in the ring beginning from 1 clockwisely and anticlockwisely. The order of numbers must satisfy the above requirements. "

Can anybody explain what this means ?
Mon Jan 26, 2004 3:13 pm
Forum: Volume 2 (200-299)
Topic: 216 - Getting in Line
Replies: 57
Views: 25135

### 216 help needed

Why do I get WA ? It works on my computer and produses right answers for the sample outputs provided ... [pascal] program GettingInLine; var si,s:array [1..1000] of integer; x,y:array [1..1000] of integer; a,r:real; stars:string; visited:array [1..1000] of boolean; function dist(x1,y1,x2,y2:real):re...
Sat Jan 10, 2004 9:04 pm
Forum: Algorithms
Topic: what is the strategy for finding ...
Replies: 1
Views: 1437

### what is the strategy for finding ...

what is the strategy for finding the shortest path between two vertices
when at certain times certain vertices are unavailable ? e.g problem 590..always on the run
Sat Dec 27, 2003 8:45 pm
Forum: Algorithms
Topic: minimum cut ?
Replies: 1
Views: 1238

### minimum cut ?

what is the algorithm used for finding the minimum number of computers that must be eliminated from a network so that the network crashes ?
is this minimum cut ? how do I implement it in Pascal ?

10x
Sat Dec 27, 2003 6:24 pm
Forum: Pascal
Topic: longest common subsequence
Replies: 1
Views: 5520

### longest common subsequence

I need the implementation of the alghoritm that determines the longest common subsequence of two arrays. unfortunately i don't know any C or C++ thanks

bye
Sat Dec 27, 2003 5:48 pm
Forum: Pascal
Topic: question
Replies: 0
Views: 4437

### question

How do you solve this type of problems in pascal ? I mean is there another way of doing this besides using an array of records that keeps the name and value for each variable..?

INPUT
JOHN=TOM+10
TOM=20

OUTPUT
JOHN=30
TOM=20
Tue Dec 23, 2003 2:37 pm
Forum: Volume 2 (200-299)
Topic: 280 - Vertex
Replies: 95
Views: 23070
I also get WA but using Pascal
Can you provide some sample test cases for me ?
Mon Dec 22, 2003 10:26 pm
Forum: Algorithms
Topic: minimum dominating set
Replies: 0
Views: 979

### minimum dominating set

any problems in the problemset that involve finding minimum dominating set ?

thanks
Fri Dec 19, 2003 3:29 pm
Forum: Algorithms
Topic: connected components
Replies: 1
Views: 1248

### connected components

Which algorithm is the best for finding the connected components in a graph ?

10x
Sun Dec 07, 2003 8:31 pm
Forum: Algorithms
Topic: problem with a tree that for you should be easy
Replies: 2
Views: 1450
Cosmin.ro wrote:You have to work with the biconnected components algo. But if you are from Cluj you should have acces to Ginfo where this is solved. Send me a private message if you really need to solve this.
lots of thanks
Sat Dec 06, 2003 6:45 pm
Forum: Algorithms
Topic: problem with a tree that for you should be easy
Replies: 2
Views: 1450

### problem with a tree that for you should be easy

Hi .. This is killing me: You are given a tree with N vertexes. Write a program, that adds (if possible) a minimum number of edges so that each vertex becomes a part of not more than ONE cycle. Sample input: n=7 1 2 1 3 3 5 3 4 5 6 5 7 sample output: 6 7 4 2 can you give me at least some basic hints...
Sun Nov 16, 2003 7:54 pm
Forum: Volume 5 (500-599)
Topic: 590 - Always on the run
Replies: 12
Views: 6900

### 590 can you give me a tiny hint

Am I the only one who doesn't know how to do that one ??
Sun Nov 16, 2003 7:47 pm
Forum: Algorithms
Topic: finding all possible paths
Replies: 2
Views: 1672

### finding all possible paths

I need an algorithm that writes ALL possible paths between two points where an adjacency matrix is given. I have no idea how to do this.Maybe you guys can help me.