BZOJ1001 [BeiJing2006] wolf to catch the rabbit plane to dual graph, minimum cut to the shortest path.

1001: [BeiJing2006]The wolf grabbed the rabbit Time Limit: 15 Sec  Memory Limit: 162 MBSubmit: 28885  Solved: 7540[Submit][Status][Discuss] Description Now the children’s favorite “Pleasant Goat and Grey Wolf” is that Grey Wolf can’t catch sheep, but it’s better to catch rabbits. And now the rabbits are stupid. They have only two nests. Now, as the wolf king, you face a grid of terrain below.   The upper left corner is (1,1), and the lower right corner is (N, M) (N=4, M=5 above). There are three types of roads. 1:(x,y)<==>(x+1,y)  2:(x,y)<==&g...

Powerful Mac cleaning tools cause you to have to choose.

In general, all operating systems clean up garbage files, so what do you need to do to clean up Apple computer garbage? Xiaobian summed up two ways: first, manual cleaning; two, use special cleaning tools to help clean up. Usually manual cleaning methods often do not achieve the desired effect, can not clean more junk files, so we will choose to clean up tools to solve, the software is now very popular clean mymac cleaning software. CleanmymacKnown as Apple’s very powerful cleaning tool, 90% of Mac users now use this software to clean their computers. It’s easy to understand, so i...

[EverydaySport] initial flag

It’s August 31, 2018. Recently, I saw a friend built a GitHub.EverydaySportRepo and his own fitness card for two years, so he made up his mind to exercise well and lose weight. objective The coach said 1 kilograms of fat, but 7000kcal. So I don’t expect to lose too fast. According to the coach’s advice, the goal isThree months, thin 6kg。that is2018November 31st 2013Weight to achieve59.8kg。 Because I always don’t insist on doing things, so I don’t know if this is a flag Bo.

JS function reference

 Maybe people don’t care too much about the parameters of a function. Simply speaking, copying values outside a function to parameters inside a function is the same as copying values from one variable to another. In-depth study, you’ll find that it’s not that simple. There are two situations in which to pass on the message (which is a mistake).,ECMAScriptThe parameters of all functions are passed by value.——《Elevation 3 The original words, here said two, because the combination of reference is easier to understand) – value reference and reference reference re...

WeChat small program view container (swiper) component to create a rotation chart

two, swiper application 1, page logic (index.js)” indicatgorDots whether there is focus. interval automatic play interval time <!--Sowing map--> <swiper indicator-dots="{{indicatorDots}}" autoplay="{{autoplay}}" interval="{{interval}}" duration="{{duration}}" indicator-color="{{indicatorColor}}" indicator-active-color="{{activeColor}}"> <block wx:for="{{imgUrls}}"> <swiper-item> <navigator url="{{item.link}}" hover-class="navigator-hover"> <image src="{{item.url}}" class="slide-image" width="355" height="200" /> ...

Java–UDP communication and TCP communication

 IPAddress and port number Port numbers are represented by two bytes (16-bit binary numbers) and range from 0 to 65535, where the port numbers between 0 and 1023 are used for some well-known network services and applications. A user’s normal application needs to use port numbers above 1024 to avoid being occupied by another application or service.      InetAddress common method Code demo: UDPSignal communication DatagramPacket    DatagramSocket  UDPNetwork program    Code demo: 1 //Sending end2 public class UDPSend {3 public static void main (String[] args) thr...

After the SpringBoot project is packaged into jar, the script is started.

Springboot projects are packaged into jars, uploaded to the server, each time you need to tap commands to redeploy the project, which you can write to the script and run directly. Startup script (start.sh): CUR_PATH=$(cd "$(dirname "$0")"; pwd) echo "Current path: ${CUR_PATH}" /usr/lib/java-1.8.0/jdk1.8.0_161/bin/java -jar ${CUR_PATH}/***.jar The red part of the code, which specifies the start of the JDK (the JDK configured by the environment variable in the server is 7, the project is based on spring boot 2.0 and requires 8.0 +) for the JDK), can be used directly.javaInstead. ***It is the ...

Record Hbase data migration and problems encountered once

Because clusters are not interworking, manual migration is adopted. 1、Download target cluster data hadoop fs -get /apps/hbase/data/data/default/*c4be21d3000064c0 /mnt/data 2、Remote replication of data, you can compress it. scp ***   3、Uploading data to HDFS must switch to HBase users, otherwise there will be errors. su hdfs hadoop fs -put /app/hbase/* /apps/hbase/data/data/default/   4、Restore metadata, etc. hbase hbck Only do a checkupHBase HBCK-fixMeta Generate the meta table according to the.Regioninfo in the region directory.HBase HBCK-fixAssignments Assign the region recor...