Time of Update: 2018-12-05
/*大水題,用比較笨的方法類比的*/#include <stdio.h>#include <string.h>int part[200][4000];int main(){int N, time, x, p, count, cal[4000], a, b, i, t;scanf( "%d", &time );while( time-- ){memset( part, 0, sizeof(part) );memset( cal, 0, sizeof(cal)
Time of Update: 2018-12-05
#include <stdio.h>#include <string.h>#include <stdlib.h>int input[6000];int n;int stack[6000];int stack_v[6000];bool deal( ){int top = 0;int topv = 0;for( int i = 0; i < n; i++ ){if( input[i] < 0 ){if( top == 0 ){stack[top++]
Time of Update: 2018-12-05
/*這道題一直RE,果然數組開小了,key word最長可以有70個字元,坑爹啊,沒看清題*//*思路就是開了一個二維數組 然後3迴圈暴力搜尋,簡單的字串匹配,沒什麼技巧,而且題上說每個keyword前後都有非字母,所以判斷的時候也很好判斷*/#include <stdio.h>#include <string.h>#include <ctype.h>int main(){ int num[75]; char temp[75]; char
Time of Update: 2018-12-05
題目大意:有個所謂的team排序, 給出t個隊伍,以及這些隊伍的成員。 然後進行排隊。 ENQUEUE x: 把x插入隊列中時。如果隊列沒有該元素的隊員,則插入隊列的最後面。如果隊列中已經有了他的隊員,那麼插入最後一個隊員之後。 DEQUEUE: 把隊頭的元素刪除,並且輸出STOP: 停止解題思路:如果對鏈表熟悉,要類比這個過程並不難。 STL 中的list挺好用的, 是雙向迴圈鏈表。 end()成員函數返回連結首位的那個迭代其。
Time of Update: 2018-12-05
產生自己定義的.pfx數位憑證 備忘:@rem 使用vs2005自動建立的.pfx數位憑證預設有效期間只有一年,並且“頒發者”、“頒發給”均為當前機器名和當前登陸使用者名稱的組合,其實我們完全可以建立更友好的.pfx數位憑證。@rem 開啟Microsoft .NET Framework 的SDK命令提示,按以下步驟操作:@rem 1、建立一個自我簽署的X.509認證(.cer)和一個.pvk私密金鑰檔案,用到makecert工具,命令如下:makecert -r -n "CN=DKSOFT"
Time of Update: 2018-12-05
//繼續字串水題,這麼水真的沒什麼可以解釋了...哈哈#include <stdio.h>#include <string.h>int main(){ char l[100], c[100]; int N, i, t, b2, e2, b4, e4; scanf( "%d", &N ); getchar(); for( t = 0; t < N; t++ ) { memset(l, 0, sizeof(l)
Time of Update: 2018-12-05
這題深搜和寬搜都可以,感覺最賤的是最後輸入的"_" input 輸入幾個底線,output輸出幾個,好吧我沒看清題wa 了3次dfs:#include <stdio.h>#include <stdlib.h>#include <string.h>#define MAX 81char map[31][81];int d[4][2] = { {1, 0}, {-1, 0}, {0, 1}, {0, -1} };int startx, starty,
Time of Update: 2018-12-05
#include <stdio.h>#include <stdlib.h>#include <string.h>#include <ctype.h>int main(){ float P, U, I; char s[300]; char temp[100]; int N, count = 0, k, i, j; scanf( "%d", &N ); getchar(); while( N-- )
Time of Update: 2018-12-05
'/r'是斷行符號,'/n'是換行,前者使游標到行首,後者使游標下移一格。通常用的Enter是兩個加起來。下面轉一篇文章。 斷行符號和換行 今天,我總算搞清楚“斷行符號”(carriage return)和“換行”(line feed)這兩個概念的來曆和區別了。 在電腦還沒有出現之前,有一種叫做電傳打字機(Teletype Model
Time of Update: 2018-12-05
http:是用於www瀏覽的一個協議。 tcp:是機器之間建立串連用的到的一個協議。IP (網際協議) 在網路通訊中,網路組件的定址對資訊的路由選擇和傳輸來說是相當關鍵的。相同網路中的兩台機器間的訊息傳輸有各自的技術協定。LAN 是通過提供6位元組的唯一識別碼(“MAC”地址)在機器間發送訊息的。SNA 網路中的每台機器都有一個邏輯單元及與其相應的網路地址。DECNET、AppleTalk 和 Novell IPX 均有一個用來分配編號到各個本地網和工作站的配置。
Time of Update: 2018-12-05
/*這道題我完全按照題目的意思先把simple input 讀入棧,然後建立符號判斷樹,然後再用隊列也就是樹的BFS搜尋,思路明確,給的資料也很簡單,一遍AC*/#include <stdio.h>#include <string.h>#include <stdlib.h>#include <ctype.h>#define MAX 12000typedef struct node{char val;struct node* left;
Time of Update: 2018-12-05
ROUND請參閱返回某個數字按指定位元取整後的數字。文法ROUND(number,num_digits) Number 需要進行四捨五入的數字。Num_digits 指定的位元,按此位元進行四捨五入。說明如果 num_digits 大於 0,則四捨五入到指定的小數位。 如果 num_digits 等於 0,則四捨五入到最接近的整數。 如果 num_digits 小於 0,則在小數點左側進行四捨五入。 樣本 公式 ------------------------------------
Time of Update: 2018-12-05
如果編譯並運行控制台程式,就會顯示一個控制台視窗,但該視窗幾乎立即就消失了,使用者幾乎看不到輸出的資訊。 原因是在建立該項目,Visual Studio .NET記住了使用者指定的設定,所以會把它編譯並運行為控制台應用程式。然後,Windows知道需要運行一個控制台應用程式,但沒有運行該程式的控制台視窗。所以,Windows就建立一個控制台視窗,並運行該程式。只要程式退出,Windows就認為不再需要該控制台視窗,因此就即時刪除了它。這些都是非常邏輯化的操作,但如果希望能看到項目的輸出結果,
Time of Update: 2018-12-05
枚舉就可以,因為剛學了dfs,所以用DFS做的,其實3個for迴圈就可以了。 #include<cstdio>#include<cmath>#include<cstring>#define HG -1e-12using namespace std;int n,sum,vis[110],temp[5];typedef struct point{ int x,y;} point;point p[110];int isok(int
Time of Update: 2018-12-05
The error as following:symptom:A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is
Time of Update: 2018-12-05
2008-09-16
Time of Update: 2018-12-05
#include <stdio.h>#include <string.h>#include <stdlib.h>#include <limits.h>#include <memory.h>#define MAX 1010#define INF 10000int n;int data[MAX][MAX];int cal[MAX];int used[MAX];int lowcost[MAX];int dijkstra( int start
Time of Update: 2018-12-05
Problem
Time of Update: 2018-12-05
這題最大難度在於英文,好吧,其實是求一個點到另外其他點的最小距離,如果小於10則記錄一次#include <stdio.h>#include <string.h>#include <stdlib.h>#include <math.h>#include <ctype.h>inline double power( double num ){return num*num;}int main(){int dis[10], a,
Time of Update: 2018-12-05
題目:Problem DescriptionDr.Kong設計了一個可以前進或後退機器人,該機器人在每個位置i會得到一個移動步數的指令Ki (i=1,2…N),聰明的機器人自己會判斷是要前進Ki步還是後退Ki步。例如:給定指令序列(3 3 1 2