-
uva10324解法(提共題目和解法程式)
題目說明:給你一連串僅包含0和1的字串 (字串長度最大到1000000,字串從第0個字元開始),要請你回答我們在第i個和第j個字元之間(包含第i個和第j個)、 是否所有的字元均相同 (均為1或均為0)。如果均相同請回答Yes、 否則請回答No。输入每筆測試資料的第一列為一個僅包含0和1的字串,下一列有1個整數n 代表對於上一列字串以下有n個問題。皆下來的 n 列每列有2個非負的整數分別代表 i和 j。输出對每一列測試字串,請先輸出第幾個的案例。然後根據 n 個問題回答肯定或否定的。解法:1.用获取讀入整行字串輸入、 並計算長度2.先判斷第 0 個位置,为 0 則把 0 存入另一個整數陣列,为 1 則存 13.用迴圈把字串陣列轉換存到整數陣列、 遇到字元 0 則值不變、 遇到字元 1 則加 14.欲判斷的i、 j位置都為字元 0、 且整數陣列i、 j位置的值相同、 代表有一連串 0、 輸出是5.欲判斷的i j位置都為字元 1,且整數陣列i、 j位置的值相減為i、 j的差、 代表有一連串 1,輸出是6.其他情況輸出号
- 2022-05-06 12:04:30下载
- 积分:1
-
chirp信号脉冲压缩,用于雷达信号处理,产生chirp信号后进行压缩,以实现高距离分辨力...
chirp信号脉冲压缩,用于雷达信号处理,产生chirp信号后进行压缩,以实现高距离分辨力-chirp signal pulse compression for radar signal processing to generate chirp signal is compressed in order to achieve high range resolution
- 2022-10-23 13:55:03下载
- 积分:1
-
Database Field ComboBox
程序TForm1.DBCBox_(pComboBox:TCustomComboBox;pQuery:TADOQuery;pFields:String数组);
- 2022-02-04 16:25:05下载
- 积分:1
-
A solar calendar of the proceedings to a solar calendar lunar calendar lunar cal...
一个阳历转阴历的程序
一个阳历阴历日期转换的程序-A solar calendar of the proceedings to a solar calendar lunar calendar lunar calendar date conversion procedure
- 2022-05-21 16:50:10下载
- 积分:1
-
Hspice仿真工具箱
hspice的matlab工具箱,可以读取Hspice的输出文件,放到matlab中处理-hspice matlab toolbox
- 2023-07-28 21:45:07下载
- 积分:1
-
C language prepared by the time the year procedures, as long as you enter a numb...
用C语言编写的时间年份程序,只要你输入一个数后,便可以马上看到结果.-C language prepared by the time the year procedures, as long as you enter a number, they can immediately see the result.
- 2022-07-02 22:38:52下载
- 积分:1
-
21-40example-c代码,是txt文本格式的,另有60例代码会陆续传上来。-21-40example-c code, txt text format. Another 60 cases will successively sent code onto.
- 2022-09-23 20:10:03下载
- 积分:1
-
through the interface configuration, generating a concealed documents and search...
通过界面配置,生成一个隐蔽查找文件及特征关键词的控制台程序。通过运行该控制台程序,就可将查找到的文件名保存到C:\_log.txt文件中了。-through the interface configuration, generating a concealed documents and search features keyword console procedures. By running the console procedures, it can find the file name to save to C : _log.txt the document.
- 2023-06-19 09:55:03下载
- 积分:1
-
four UNIX operating function Message Queue
四种UNIX消息队列操作函数-four UNIX operating function Message Queue
- 2022-04-25 16:00:35下载
- 积分:1
-
模仿港台《百万富翁》节目,具有很强的娱乐性和知识性,
模仿港台《百万富翁》节目,具有很强的娱乐性和知识性,-imitate Hong Kong and Taiwan "millionaire" program is highly entertaining and informative.
- 2022-11-21 23:30:03下载
- 积分:1