原创 用tarjan縮點重建圖

嘗試一下縮點減新圖。代碼應當是poj2186的,但是poj崩了,也不知代碼對不對。。。 #include<iostream> #include<string> #include<stack> #include<vector> us

原创 POJ3268Silver Cow Party

題意:給出n個點和m條邊,接着是m條邊,代表從牛a到牛b需要花費c時間,現在所有牛要到牛x那裏去參加聚會,並且所有牛參加聚會後還要回來,給你牛x,除了牛x之外的牛,他們都有一個參加聚會並且回來的最短時間,從這些最短時間裏找出一個最

原创 POJ - 3169Layout差分約束+spfa

Like everyone else, cows like to stand close to their friends when queuing for feed. FJ has N (2 <= N <= 1,000) cow

原创 2017 計蒜之道 初賽 第六場 微軟大樓設計方案(中等)

網址:https://nanti.jisuanke.com/t/15773 近日,微軟新大樓的設計方案正在廣泛徵集中,其中一種方案格外引人注目。在這個方案中,大樓由 nn 棟樓組成,這些樓從左至右連成一排,編號依次爲 11 到

原创 python3爬蟲 爬取mzitu.com & meitulu.com圖片按名搜索

網址:mzitu.com & meitulu.com 功能:按名搜索,該名稱下所有圖集 import urllib.request from urllib.parse import quote from lxml import e

原创 POJ - 2240Arbitrage

Arbitrage is the use of discrepancies in currency exchange rates to transform one unit of a currency into more than

原创 POJ 2253 Frogger

Freddy Frog is sitting on a stone in the middle of a lake. Suddenly he notices Fiona Frog who is sitting on another

原创 POJ - 3159Candies差分約束+spfa

During the kindergarten days, flymouse was the monitor of his class. Occasionally the head-teacher brought the kids

原创 整理《挑戰程序設計競賽》中最短路的代碼

一.Bellman-Ford 核心公式: d[i]=min(d[j]+e.cost,d[i]) 釋: d[i]:i節點到源點的當前最短距離 e.cost:相鄰兩節點的距離(公式中的爲j節點指向i節點的距離) 原因:

原创 POJ 1797 Heavy Transportation

Background Hugo Heavy is happy. After the breakdown of the Cargolifter project he can now expand business. But he

原创 poj1860Currency Exchange

Several currency exchange points are working in our city. Let us suppose that each point specializes in two particu

原创 POJ - 1502MPI Maelstrom

BIT has recently taken delivery of their new supercomputer, a 32 processor Apollo Odyssey distributed shared memory

原创 POJ - 1847Tram dijkstra

Tram network in Zagreb consists of a number of intersections and rails connecting some of them. In every intersecti

原创 2019年網課 高校邦 魅力數學 測試題

應付考試,ctrl+f輸入部分題目自行查找,也可以下載文末文檔 在電腦中,一個漢字的存儲需要兩個字節,也就是2B。那麼存儲一億個漢字約需要多少空間?C. 200MB 下面哪一種的變化更接近於指數增長?D. 歷史上全球人口隨時間的增

原创 POJ - 1511Invitation Cards

In the age of television, not many people attend theater performances. Antique Comedians of Malidinesia are aware o