編譯原理的一個語法分析程序,設計,編制并調試一個語法分析程序,加深對語法分析原理的理解。可以編譯c語言的基本結構,包括循環嵌套和條件嵌套。(1) 執行程序時,可輸入源程序的路徑,如果輸入為空的話,將會編譯默認的源程序“./input.dat” (2) 如果編譯發現有錯誤,則會輸出錯誤行數,并在結束編譯時輸出“Complete!”
上傳時間: 2016-04-11
上傳用戶:許小華
Problem D:合唱隊形 Time Limit:1000MS Memory Limit:65536K Total Submit:1237 Accepted:437 Language: not limited Description N位同學站成一排,音樂老師要請其中的(N-K)位同學出列,使得剩下的K位同學排成合唱隊形。 合唱隊形是指這樣的一種隊形:設K位同學從左到右依次編號為1,2…,K,他們的身高分別為T1,T2,…,TK, 則他們的身高滿足T1 < T2 < ...< Ti > Ti+1 > … >TK(1<=i<=K)。 你的任務是,已知所有N位同學的身高,計算最少需要幾位同學出列,可以使得剩下的同學排成合唱隊形。 Input 輸入包含若干個測試用例。 對于每個測試用例,輸入第一行是一個整數N(2<=N<=100),表示同學的總數。第二行有N個整數,用空格分隔,第i個整數Ti(130<=Ti<=230)是第i位同學的身高(厘米)。當輸入同學總數N為0時表示輸入結束。 Output 對于每個測試案例,輸出包括一行,這一行只包含一個整數,就是最少需要幾位同學出列。 Sample Input 8 186 186 150 200 160 130 197 220 3 150 130 140 0 Sample Output 4 1
標簽: Limit Accepted Language Problem
上傳時間: 2014-01-13
上傳用戶:aappkkee
對于符號三角形問題,符號三角形的第一行有n個符號。符號可以為“+”或“-”,以下每一行的符號由上行得到,2個同號下面都是“+”,2個異號下面都是“-”。如下圖所示(第一行有4個符號的符號三角中的其中的一個): 符號三角形問題要求對于給定的n,計算有多少個不同的符號三角形,使其所含的“+”和“-”的個數相同。 Input 輸入包含若干個測試用例。 對于每個測試用例,輸入的一行是一個整數n(2<=n<=20),表示符號三角形第一行符號的個數。當輸入n為0時表示輸入結束。 Output 對于每個測試案例,輸出包括一行,這一行只包含一個整數,就是該測試案例總共有多少不同的符號三角形,使其所含的“+”和“-”的個數相同。 Sample Input 2 3 0 Sample Output 0 4
上傳時間: 2014-01-02
上傳用戶:陽光少年2016
Problem F:汽車加油 Time Limit:1000MS Memory Limit:65536K Total Submit:1400 Accepted:404 Language: not limited Description 一輛汽車加滿油后可行駛n公里。旅途中有若干個加油站。設計一個有效算法,指出應在哪些加油站停靠加油,使沿途加油次數最少。 編程任務: 對于給定的n和k(k <= 10000)個加油站位置,編程計算最少加油次數。 Input 第一行有2 個正整數n和k,表示汽車加滿油后可行駛n公里,且旅途中有k個加油站。接下來的1 行中,有k+1 個整數,表示第k個加油站與第 k-1 個加油站之間的距離。第0 個加油站表示出發地,汽車已加滿油。第k+1 個加油站表示目的地。 Output 輸出最少加油次數。如果無法到達目的地,則輸出”No Solution”。 Sample Input 7 7 1 2 3 4 5 1 6 6 Sample Output 4
標簽: Limit Accepted Language Problem
上傳時間: 2016-04-12
上傳用戶:youth25
Squaring circuits are an important building block for impulse-radio UWB non-coherent receivers. This work proposes a squarer, based on the quadratic law of saturated transistors. Such a circuit has already been proposed for lower frequency applications, therefore this work focuses on the extension to ultra wide bandwidth, with particular care to the consequences related to the deviation from the ideal quadratic law of 0.18μm CMOS transistors.
標簽: impulse-radio non-coherent important receivers
上傳時間: 2013-12-24
上傳用戶:kikye
In this letter, the error performance of an ultra-wideband (UWB) system with a hybrid pulse amplitude and position modulation (PAPM) scheme over indoor lognormal fading channels is analyzed. In the PAPM UWB system, input data is modulated onto both the pulse amplitudes and pulse positions.
標簽: ultra-wideband performance amplitud letter
上傳時間: 2014-01-08
上傳用戶:yulg
北京大學ACM題 Here is a geometric problem. You have an angle and some squares in the first quadrant of the plane rectangular coordinates. The vertex of the angle is fixed on the origin O of the coordinates, and both of its radial lines are specified by the input. The sizes of the squares are also specified by the input, and the squares can shift vertically and horizontally. Now your job is to use the squares and the radial lines of the angle to enclose the maximum area, which excludes the area of the squares (see Figure 1). You should note that the edges of the squares must be parallel to the axes.
標簽: geometric quadrant problem squares
上傳時間: 2013-12-25
上傳用戶:ynzfm
PlotSphereIntensity(azimuth, elevation) PlotSphereIntensity(azimuth, elevation, intensity) h = PlotSphereIntensity(...) Plots the intensity (as color) of a number of points on a unit sphere. Input: azimuth (phi), in degrees elevation (theta), in degrees intensity (optional, if not provided, a green sphere is produced) All inputs must be vectors or matrices of the same size. Data does not have to be evenly spaced. When there aren t enough points to draw a smooth sphere, additional points (with color) are interpolated. Output: h - a handle to the patch object The axes are also plotted: positive x axis is red positive y axis is green positive z axis is blue
標簽: PlotSphereIntensity elevation azimuth intensity
上傳時間: 2014-01-15
上傳用戶:ruan2570406
第一章:Internetworking 第二章:Internet Protocols 第三章:IP Subnetting and Variable Length Subnet Masks(VLSM) 第四章:Introduction to the Cisco IOS 第五章:IP路由 第六章:Enhanced IGRP(EIGRP) and Open Shortest Path First(OSPF) 第七章:Layer 2 Switching 第八章:Virtual LANs(VLANs) 第九章:Managing a Cisco Interwork 第十章:Managing Traffic with Access Lists 第十一章:Wide Area Networking Protocols
標簽: Internetworking Subnetting Protocols Internet
上傳時間: 2014-01-05
上傳用戶:qiao8960
The neuro-fuzzy software for identification and data analysis has been implemented in the MATLAB language ver. 4.2. The software trains a fuzzy architecture, inspired to Takagi-Sugeno approach, on the basis of a training set of N (single) output-(multi) input samples. The returned model has the form 1) if input1 is A11 and input 2 is A12 then output =f1(input1,input2) 2) if input1 is A21 and input 2 is A22 then output =f2(input1,input2) 看不懂,據高手說,非常有用。
標簽: identification neuro-fuzzy implemented analysis
上傳時間: 2014-01-12
上傳用戶:zgu489