1029: snow cleaning, 1029 snow cleaning

Source: Internet
Author: User
Tags aliyun

1029: snow cleaning, 1029 snow cleaning
Description

James's city had a heavy snow last night and all the roads were covered with snow. In order to ensure smooth traffic, snow removal vehicles need to be used to clean up the snow on the road, but the city only has one snow removal vehicle.
There are two lanes for each road in the city. A Snow-removing vehicle can clear the snow on one road in one way, and a snow-removing vehicle can change its direction (including U-shaped turns) at any intersection ), at the same time, you can turn around (U-shaped) at the end of any road to another lane.
The snow-removing vehicle is driving at a speed of 20 km/h during the snow-removing process, and traveling at a speed of 50 km/h on the Lane where the snow has been cleared.
Now, how long does it take for the snow-removing vehicle to clear all lanes on all roads and finally return to the garage?

Input Format

The first line of the input contains two integers x and y, indicating the coordinates of the garage where the snow-removing car is parked.
In the next several rows, input four real numbers x1, y1, x2, y2 in each row to indicate the starting point coordinates of a certain road. All roads are straight roads.
The coordinates of the garage must be on the line segment of a certain road.
All coordinate units in the input are meters.

Output

The minimum time required for returning to the garage after cleaning all lanes of all roads is output, in the format of hh: mm. The result is rounded to minutes.

Sample Input

0 0
0 0 10000 10000
5000-10000 5000 10000
5000 10000 10000 10000

Sample output

3:55

How is the shortest possible?

One track is divided into two lines, and you can jump to the other to clean up at the end of the cleaning. The minimum time is to clear the snow and return to the origin. Remember to clean up the snow of the two lines.

 1 #include<stdio.h> 2 #include<math.h> 3  4 int main() 5 { 6         double x1,y1,x2,y2,s=0,t; 7         int m; 8         scanf("%*d%*d"); 9         while(scanf("%lf%lf%lf%lf",&x1,&y1,&x2,&y2)!=EOF)10                 s+=sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2));11         t=s/20000*2;12         m=(t-(int)t)*60+0.5;13         if(m==60)14                 printf("%02d:00\n",(int)t+1);15         else16                 printf("%02d:%02d\n",(int)t,m);17         return 0;18 }

 


How can snow be cleared at high speed?

In this case, the Northeast China will be able to deal with it;
If salt or industrial Brine is used in urban areas, how many vehicles are needed to load salt or salt water at a high speed? The cost is too high, and the loss of money

How to clear road snow

Most of China's Qinling Mountains, north of the Huaihe River, and Qinghai-Tibet Plateau have snow cleaning problems in urban roads. With the popularization of Urban Pavement hardening and the increase of vehicle inventory in cities, the urban traffic safety issue has been paid more and more attention by people.
# QdQ! Q? QY0 ?? As snow increases traffic security risks, winter snow is an important task in cities, and municipal and environmental sanitation departments have become the main force in city snow clearing.
X % zS + Ioo/e0 ?? Based on our practices in recent years, we have put forward some suggestions on Urban Road Snow cleaning for reference by leaders at all levels, sanitation colleagues, and comrades in charge of snow cleaning. Zhejiang boknet K (Uo \ d. pK
?? I. Snow is a kind of resource, so it is not necessary to clear the snow outside the city.
?? When organizing snow cleaning work in many cities, it is always required to transport snow outside the city. It seems that there should be no place for snow in the city. In fact, this is completely a method of labor and financial losses. On the one hand, it wastes a lot of manpower, material resources, financial resources, and energy. On the other hand, it also wastes valuable snow resources. Zhejiang boknet n4r $ s! \ % \ W) t
?? Snow is a form of precipitation in cold areas. It is a resource, a water source, and a valuable asset that nature presents to humans. Snowfall in winter has great benefits for agricultural production, human health, and environmental purification.
} 9a? U: Mp {A0 ?? 1. Snow is a "natural muffler ".
5 ^: Bf $ e/H0os0 ?? Low snow density, low quality, large gaps, and strong noise absorption. Cities after Snow can reduce noise pollution to the environment. Http://service.ap-southeast-1.maxcompute.aliyun-inc.com/api
?? 2. Snow can increase the humidity in the air.
O7VD % [^ hwB \ 0 ?? Various cement buildings, structures, and roads in the city block water exchange between heaven and earth. The surface water cannot penetrate into the ground, and the groundwater cannot evaporate into the air to form a dry city. The existence of snow will undoubtedly increase the humidity in the urban air and ease the city's drought.
/SE9W} % ['sw % V3zU 'u0 ?? 3. Snow is an important source of groundwater. J' @ wo] r * e; q + d
?? In many cities, over-exploitation of groundwater has caused environmental geological problems such as land subsidence. After the snow melted, the groundwater can be effectively supplemented.
T \ m (U + C # lah0 ?? 4. Snow is the nemesis of infectious diseases.
''+ Y | 1Sa0 ?? In normal years, many infectious diseases and bacteria are restricted by the cold weather. This cold and cold will cause prolonged weather conditions for the bacteria, leading to the prevalence of diseases. When the snow melts, a large amount of heat should be absorbed. 1 gram of ice with 0 degrees should be melted into 0 degrees of water, and the heat of 334.4 joules should be absorbed. Snow covers the ground. On the one hand, it can reflect the heat from the sun to the ground. On the other hand, it can take away a large amount of heat when the snow melts, which is of great significance to prevent the temperature from high in winter, this effectively prevents the spread of infectious diseases and bacteria. Http://service.ap-southeast-1.maxcompute.aliyun-inc.com
?? 5. Snow can eliminate pests and bacteria in the green belts. Http://service.ap-southeast-1.maxcompute.aliyun-inc.com/api ~ Md6z e
?? When the snow melts, it is necessary to absorb a large amount of heat from the surrounding area, which will lead to a sudden decrease in the temperature near the soil surface and the root of the winter plant. Sudden cooling will cause the pests and bacteria in the weeds to be frozen to death. The snow on the ground blocks the flow of air in the upper and lower layers of the snow layer, resulting in insufficient oxygen in the soil layer, so that pests and eggs are suffocated. When the snow melts, the soil surface water increases, or even reaches the saturation state, so that the pests that lie on the soil surface often die due to excessive water. The bactericidal effect of snow is better than that of a pesticide. Http://service.ap-southeast-1.maxcompute.aliyun-inc.com/api! Dyir3A | m
?? Snow brings so many benefits to humans. Why should we clear the snow out of the city? Http://service.ap-southeast-1.maxcompute.aliyun-inc.com/api ~ Q
?? Our goal is to prevent road snow from interfering with traffic, rather than eliminating snow in the city. The city's green belts and idle places can be the shelter of snow everywhere, as long as the snow does not pose a threat to urban traffic security, it is not necessary to ...... the remaining full text>

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.