Problem F:汽車加油 Time Limit:1000MS Memory Limit:65536K Total Submit:1400 Accepted:404 Language: not limited Description 一輛汽車加滿油后可行駛n公里。旅途中有若干個(gè)加油站。設(shè)計(jì)一個(gè)有效算法,指出應(yīng)在哪些加油站停靠加油,使沿途加油次數(shù)最少。 編程任務(wù): 對(duì)于給定的n和k(k <= 10000)個(gè)加油站位置,編程計(jì)算最少加油次數(shù)。 Input 第一行有2 個(gè)正整數(shù)n和k,表示汽車加滿油后可行駛n公里,且旅途中有k個(gè)加油站。接下來的1 行中,有k+1 個(gè)整數(shù),表示第k個(gè)加油站與第 k-1 個(gè)加油站之間的距離。第0 個(gè)加油站表示出發(fā)地,汽車已加滿油。第k+1 個(gè)加油站表示目的地。 Output 輸出最少加油次數(shù)。如果無法到達(dá)目的地,則輸出”No Solution”。 SAMple Input 7 7 1 2 3 4 5 1 6 6 SAMple Output 4
標(biāo)簽: Limit Accepted Language Problem
上傳時(shí)間: 2016-04-12
上傳用戶:youth25
1) Write a function reverse(A) which takes a matrix A of arbitrary dimensions as input and returns a matrix B consisting of the columns of A in reverse order. Thus for example, if A = 1 2 3 then B = 3 2 1 4 5 6 6 5 4 7 8 9 9 8 7 Write a main program to call reverse(A) for the matrix A = magic(5). Print to the screen both A and reverse(A). 2) Write a program which accepts an input k from the keyboard, and which prints out the smallest fibonacci number that is at least as large as k. The program should also print out its position in the fibonacci sequence. Here is a SAMple of input and output: Enter k>0: 100 144 is the smallest fibonacci number greater than or equal to 100. It is the 12th fibonacci number.
標(biāo)簽: dimensions arbitrary function reverse
上傳時(shí)間: 2016-04-16
上傳用戶:waitingfy
usb bulk 傳輸例程。 * The bulkusb driver is a generic function driver, based on the Windows Driver Model (WDM). * Supports Plug and Play(PnP), Power Management(PM), Windows Management Instrumentation (WMI) and the Selective Suspend (SS) features. * This SAMple is based off the selSusp DDK SAMple. Please refer the selSusp SAMple and the DDK docs to understand the handling of PnP, PM, WMI and SS features and implementations. * The USB device used for this SAMple is a generic Intel I82930 USB evaluation board programmed with a simple loopback test using a 64 KB circular buffer. None of the code in the SAMple is specific to this controller chip.
標(biāo)簽: driver function Windows bulkusb
上傳時(shí)間: 2016-04-25
上傳用戶:270189020
Hybrid Monte Carlo sampling.SAMpleS = HMC(F, X, OPTIONS, GRADF) uses a hybrid Monte Carlo algorithm to SAMple from the distribution P ~ EXP(-F), where F is the first argument to HMC. The Markov chain starts at the point X, and the function GRADF is the gradient of the `energy function F.
標(biāo)簽: Carlo Monte algorithm sampling
上傳時(shí)間: 2013-12-02
上傳用戶:jkhjkh1982
Probability distribution functions. estimation - (dir) Probability distribution estimation. dsamp - Generates SAMples from discrete distribution. erfc2 - Normal cumulative distribution function. gmmsamp - Generates SAMple from Gaussian mixture model. gsamp - Generates SAMple from Gaussian distribution. cmeans - C-means (or K-means) clustering algorithm. mahalan - Computes Mahalanobis distance. pdfgauss - Computes probability for Gaussian distribution. pdfgmm - Computes probability for Gaussian mixture model. sigmoid - Evaluates sigmoid function.
標(biāo)簽: distribution Probability estimation functions
上傳時(shí)間: 2016-04-28
上傳用戶:13188549192
flash lite開發(fā) ArcadeHeroes.swf SWF content games/invaders.swf SWF content games/pacman.swf SWF content Arcade1_2nd_edition.SIS Nokia S60 2nd Edition SIS package Arcade1_3rd_edition_signed.sis Nokia S60 3rd Edition signed SIS package Arcade1_2nd_edition.pkg Nokia S60 2nd Edition SIS Package descriptor Arcade1_3rd_edition.pkg Nokia S60 3rd Edition SIS Package descriptor makesis.php PHP script mykey.key SAMple certificate key, created using makekeys.exe mycert.cer SAMple certificate, created using makekeys.exe makekeys.exe Symbian application to create signing keys
標(biāo)簽: content SWF swf games
上傳時(shí)間: 2014-01-22
上傳用戶:hn891122
Addfilter is a command-line application which adds and removes filter drivers for a given drive or volume. It is intended to demonstrate how to insert a filter driver into the driver stack of a device. The SAMple illustrates how to do this by using the SetupDi APIs. The SAMple works on the x86 platform. It has only been tested in a 32-bit environment. Since Addfilter is not a driver, it does not deal with Plug and Play or Power Management.
標(biāo)簽: command-line application Addfilter drivers
上傳時(shí)間: 2016-05-17
上傳用戶:xzt
Zword公司的Rabbit2000系列相關(guān)文件,包含庫Lib和例子SAMple,也有TCP/IP相關(guān)應(yīng)用文件,配套的軟件為Dynamic C .
上傳時(shí)間: 2016-05-26
上傳用戶:hgy9473
The full Fusion SDK consists of a directory of header files (*.h), the eyeonSystem.lib file and the eyeonScript.lib file. We have also included some SAMple plug‐ins to help get you acquainted with the Fusion plug‐in architecture.
標(biāo)簽: eyeonSystem directory the consists
上傳時(shí)間: 2016-06-07
上傳用戶:dancnc
this application program demonstrate programming and simulation of the on-chip CAN (controller area network) interface of the C167/ST10-F168. The SAMple source code can be compiled using keil C166 compiler. To test the program you may use the uVision2 debugger/simulator that is part of keilPK166 package.
標(biāo)簽: application demonstrate programming controller
上傳時(shí)間: 2013-12-11
上傳用戶:zmy123
蟲蟲下載站版權(quán)所有 京ICP備2021023401號(hào)-1