Find Jobs
Hire Freelancers

Ada Programming

$10-30 USD

完了済み
投稿日: 10年以上前

$10-30 USD

完了時にお支払い
A cell phone company is continually building and leasing communication towers. Each tower has a one-way communcation link to a least one other tower. The input to the program is essentially a list of pairs of tower names. Each pair will appear on a single line and will contain distinct names. Some pairs represent one-way communcation links between towers, and other pairs represent queries. Links and queries may be interspersed. All the communication links of the system are added one link at a time. Here is an example of a link: Tower_A Tower_B. A link is terminated by a period. A query asks if a communcation link is possible from one tower to another by any combination of one-way links. If another link is added to the system later in the input, then the answer to the same query may be different. In the output, a plus sign (+) represents an affirmative answer; a minus sign (-) says there is no such link. Links are distinguished from queries by ending in a question mark and not a period. Sample Input and Output The program should read from the standard input and and write to the standard output. For each query in the input there should be exactly one line of output. If the query is true (there is a communication channel through the network), the output line should begin with a plus sign (+); otherwise with a minus sign (-). The rest of the output line repeats the towers in the query. For the following input: Tower_A Tower_B. Tower_B Tower_C . Tower_A Tower_C? # A query Tower_B Tower_D. Tower_A Tower_D ? # Another query Tower_F Tower_E. Tower_D Tower_B ? # A third query xxxx yyyy? # Unknown tower names the output should be + Tower_A => Tower_C + Tower_A => Tower_D - Tower_D => Tower_B - xxxx => yyyy The names of the towers will contain only the characters [a-zA-Z_0-9], in particular they will have no spaces in them. Names will have at least 1 character and no more than 50 characters. Furthermore the capitialization of the names is significant. That is, WestMelbourneTower is not to be considered the same tower as wESTMeLbOuRnEtOwEr. Characters, if any, after the period (.) or question mark (?) on a line are to be ignored. No line will will contain more than 150 characters.
プロジェクト ID: 5082057

プロジェクトについて

3個の提案
リモートプロジェクト
アクティブ 11年前

お金を稼ぎたいですか?

Freelancerで入札する利点

予算と期間を設定してください
仕事で報酬を得る
提案をご説明ください
登録して仕事に入札するのは無料です
アワード者:
ユーザーアバター
This project involves an implementation of a graph structure and a search algorithm, like BFS. I can implement this in Java or C++ in 1 day.
$30 USD 1日以内
5.0 (1 レビュー)
1.0
1.0
この仕事に3人のフリーランサーが、平均$28 USDで入札しています
ユーザーアバター
Hi I am a Computer Engineer and I have 1 year experience in JAVA I am also good at Data structure and Algorithm Please check my current project in my profile I can do your work very efficiently and quickly Thank you :)
$30 USD 1日以内
5.0 (6 レビュー)
2.9
2.9
ユーザーアバター
I am a software engineer. IIT delhi graduate in Computer Science. I am very good in java and algorithms.
$25 USD 1日以内
0.0 (0 レビュー)
0.0
0.0

クライアントについて

UNITED STATESのフラグ
Melbourne, United States
5.0
14
お支払い方法確認済み
メンバー登録日:5月 24, 2011

クライアント確認

ありがとうございます!無料クレジットを受け取るリンクをメールしました。
メールを送信中に問題が発生しました。もう一度お試しください。
登録ユーザー 投稿された仕事の合計
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
プレビューを読み込み中
位置情報へのアクセスが許可されました。
あなたのログインセッションの有効期限がきれ、ログアウトされました。もう一度ログインしてください。