原创 memcpy()函數和strcpy()函數的使用方法

一.memcpy( )函數 頭文件: #include<string.h> 函數: memcpy(b,a,n);//把數組a中前n爲字符複製到數組b中; 結果: b數組中存儲一個長度爲n的字符串,和數組a的前n位相同; 注意: 因爲數組的

原创 memcmp ( ) 函數和strcmp( )函數的使用方法

一.memcmp()函數 頭文件: #include<string.h> 函數: memcmp ( a , b , n );//a和b是兩個數組,n 是你想要比較的長度; 結果: 如果a比b大,返回值大於0; 如果a比b小,返回值小於0;

原创 7-2 鏈表去重 (25 分)

題目: 給定一個帶整數鍵值的鏈表 L,你需要把其中絕對值重複的鍵值結點刪掉。即對每個鍵值 K,只有第一個絕對值等於 K 的結點被保留。同時,所有被刪除的結點須被保存在另一個鏈表上。例如給定 L 爲 21→-15→-15→-7→15,你需要

原创 Backward Digit Sums POJ - 3187 (枚舉+全排列)

題目: FJ and his cows enjoy playing a mental game. They write down the numbers from 1 to N (1 <= N <= 10) in a certain or

原创 Play on Words UVA - 10129 (歐拉回路)

題目: Some of the secret doors contain a very interesting word puzzle. The team of archaeologists has to solve it to open

原创 abs()和fabs()的區別

一.abs() 頭文件:#include<stdlib.h> 函數:int  s = abs ( k ) ; 代碼如下: #include<stdio.h> #include<stdlib.h> int main() { in

原创 Tomcat 啓動JRE不正確和界面亂碼

前言: 最近裝了Tomcat,但是一直有各種各樣的問題無法解決,百度了一堆東西纔算是解決了問題。下面我把問題總計一下。 一、Tomcat啓動總是JRE不正確 問題:顯示JRE不正確,那麼肯定是JRE的路徑沒有被正確的找到,那麼我們就對於J

原创 第三屆藍橋杯國際賽總結----德國行

前言:         原諒我的懶,已經回來好多天了,現在纔開始準備寫寫自己的總結收穫。         2019.11.1早上八點,飛機降落在首都國際機場,那一刻,意味着我的藍橋杯國際賽的行程是真的完全結束了。擠地鐵,趕向高鐵站,老師請

原创 CodeBlocks找不到編譯器的解決方法

前言: 電腦重裝了系統,安裝了Code Blocks,發現代碼不能夠編譯,顯示找不到編譯器。 解決辦法: 錯誤是因爲默認的編譯器的位置發生了改變,找不到編譯器的位置,那麼就需要把編譯器的位置進行修改就可以了。 步驟: 1.在CodeBlo

原创 River Hopscotch POJ - 3258 (二分搜索枚舉判斷)

題目: Every year the cows hold an event featuring a peculiar version of hopscotch that involves carefully jumping from ro

原创 Tudoku POJ - 2918

題目: Tom is a master in several mathematical-theoretical disciplines. He recently founded a research-lab at our universi

原创 Desert King POJ - 2728(最優比率生成樹)

題目: David the Great has just become the king of a desert country. To win the respect of his people, he decided to build

原创 GCD and LCM Aizu - 0005

題目: Write a program which computes the greatest common divisor (GCD) and the least common multiple (LCM) of given a and

原创 Dropping tests POJ - 2976 (二分搜索 01分數規劃)

題目: In a certain course, you take n tests. If you get ai out of bi questions correct on test i, your cumulative average

原创 Save your cats Aizu - 2224 (最大生成樹)

題目: Problem C: Nicholas Y. Alford was a cat lover. He had a garden in a village and kept many cats in his garden. The c