由文件input.txt提供輸入數據。輸入文件第1 行有2個正整數n和m(1<=n,m<=100),
表示倉庫是n×m個格子的矩形陣列。接下來有n行,每行有m個字符,表示格子的狀態。
S 表示格子上放了不可移動的沉重貨物;
w 表示格子空閑;
M 表示倉庫管理員的初始位置;
P 表示箱子的初始位置;
K 表示箱子的目標位置。
A software input panel, a virtual keyboard for windows mobile/PocketPC. It is a undochable floating SIP with only numeric input for calculators etc.. Uses bitmap buttons.
Solve the 8-puzzle problem using A * algorithme.
Input: Program reads start state and goal state and heuristic (N or S) from EightPuzzle.INP file.0 representing blank.
There are 2 Heuristic:
1. N: Number of misplaced tiles
2. S: Sum of Manhattan distance of current location and target location.
Format: The first line write type of heuristic (N or S).
Next is the status of departing and landing status. Between 2 states of 1 line blank.
See examples EightPuzzle.INP
The function applies the Madsen method for Doppler Centroid estimation. The input are:
1) the raw data, the parameter of the distance between samples in azimuth to be correlated and the PRF (Pulse repetition frequency)
Calculates if the brackets in a sentence are correctly close.
Input consists, one per line, sentences with brackets, and output say YES if its correctly close, or NO int if its not saying where is the error.
Input:
()[]<>(**)
(*)
(ASA
Output:
YES
NO 2
NO 4
Implementation of Edmonds Karp algorithm that calculates maxFlow of graph.
Input:
For each test case, the first line contains the number of vertices (n) and the number of arcs (m). Then, there exist m lines, one for each arc (source vertex, ending vertex and arc weight, separated by a space). The nodes are numbered from 1 to n. The node 1 and node n should be in different sets. There are no more than 30 arcs and 15 nodes. The arc weights vary between 1 and 1 000 000.
Output:
The output is a single line for each case, with the corresponding minimum size cut.
Example:
Input:
7 11
1 2 3
1 4 3
2 3 4
3 1 3
3 4 1
3 5 2
4 6 6
4 5 2
5 2 1
5 7 1
6 7 9
Output:
5