已完成

Program C++

For this project you will be designing and implementing a system in C++ (98, 11, or 14), that simulates a forest fire. The locations of the trees in the area and how long they take to burn will be provided in one file, while the weather information concerning wind direction and rain will be provided in another. Based on the wind direction, your system should display how the fire spread through the forest, halt when there are no more burning trees, and report the total number of days it took for the fire to stop.

Your program must provide the following functionality and adhere to the following constraints:

 Allow the user to input the file describing the initial condition of the forest:

o Do NOT hardcode the filename into your program

o The first line will specify how many days a tree burns for

o All other lines will be comma delimited containing the following characters:

 ‘T’ is a tree that is not on fire

 ‘F’ is a tree that is on fire

 ‘B’ is a tree that has already burnt down

 ‘ ‘ is an empty patch of land

o The forest can be any sized rectangle

o Assume the top of the grid is North

 Allow the user to input the file describing the weather forecast

o Do NOT hardcode the filename into your program

o Each line will specify the weather for that day:

 ‘N’ indicates the wind is blowing to the North

 ‘S’ indicates the wind is blowing to the South

 ‘W’ indicates the wind is blowing to the West

 ‘E’ indicates the wind is blowing to the East

 ‘R’ indicates that it is raining and there is no wind blowing

o If the weather is not specified for a day, then assume it is the same as the previous day

o The weather will always be specified for Day 0

 Once initialized, your system should simulate the forest fire in the following way:

o The initial condition of the forest, as specified in the file, represents Day 0 of the fire, and should be output in a grid format

o During every day in which there is at least one tree still on fire:

 The weather should first be checked for that day, if it changed the user should be notified of the change

 If it is not raining, then the fire should spread according to the direction of the wind. For example, if the wind is blowing to the South, then the fire can only spread to trees south of it:

 Similarly, if the wind is blowing to the North, then the fire can only spread to trees north of it, and so on for West and East

 If it is raining, then no wind is blowing and the fire cannot spread that day

 A tree can only set other trees on fire the day after it was set on fire

 After a tree has burned for the specified number of days, it becomes a ‘B’ representing a burnt down tree. Day 0 does count as a day for a tree burning

 Finally, the current condition of the forest should be output in a grid format, a long with its day number.

o Once there are no trees on fire, the simulation should halt, output the final condition of the forest, and specify how many day s the fire took to burn. Day 0 should be included in this count, but the first day with no fires should not.

Additional information can be provided as we progress with the project.

技能: .NET, C 编程, C# 编程, C++编程, 软件构架

查看更多: c++ programs with output pdf, c++ programs examples with output, c++ programming examples and solutions, c++ code examples, c++ program codes, c++ programs for beginners, c++ programs list, c++ programs pdf, freelance linux program c, program c, program c online, cannot run program c users leila appdata local android sdk tools android bat createprocess error 2 the system cannot find the fi, program c++ freelance, program c# online, program c++ online, R.E.A.C.H, how to program c++, basic windows program c++, s.e.c.r.e.t trilogy, s.e.c.r.e.t book series

关于此雇主:
( 1条评论 ) Denton, United States

项目ID: #19974950

授予:

it2051229

Hi there, I went through the requirements and I realized that I did this project for someone a few years ago. I would like to do it again if given the opportunity. Let me know if you are interested.

$30 USD 在1天内
(1018条评论)
7.6

12 威客就此工作平均出价 $52

DevStar925

Hi, Dear Employer! I am really interested in your project. I have enough experience in Python, C/C++, C#, java programming. I am 100% sure I can satisfy your requirements perfectly. User-Friendly Interface And Clear A 更多

$150 USD 在3天内
(74条评论)
7.3
utkarshkatiyar19

Hi, I’m an expert in c++ programming. I’m sure that I can easily do this project for you. We can have a chat.

$60 USD 在2天内
(373条评论)
7.3
YanLee911

Dear sir Thank you for giving me this opportunity to bid on your project. I read your job requirement and wish I can work on your project. I've a rich experience in the developments with c, c++ and c#, and I'm able 更多

$50 USD 在3天内
(5条评论)
3.8
slobodanivkovic

Hello, I read and understood all the requirements and checked input and output files. This is fairly simple task for me and can be finished in no time. If you are interested send me a message. Best regards, Slobodan

$35 USD 在3天内
(3条评论)
2.4
RajdeepWasekar

Hi I’m introduced in your project and I would love to work on it. Hire me, I will do the job shortly. Thanks

$50 USD 在3天内
(1条评论)
2.1
hereafter2

Lab time. I will implement the solution in C++ 14. will pass all test cases and ensure a good score in terms of code quality. B.T.W, are you cheating?

$30USD 在1天里
(1条评论)
2.2
ninestar801

Hi, Hope you are doing well! I would like to work on your project. I have excellent skills in typing, MS Excel, MS Word, MS PowerPoint, Data Entry, Data scraping, pdf conversion and office skills with more than 6 Years 更多

$100 USD 在7天内
(0条评论)
0.0
evonsystems7

"Hi, Hope you are doing well! Thanks for sharing your project requirement with us. It will be our great pleasure to work on your project. I have checked your requirement, yes we can do it, because we already work on si 更多

$27 USD 在7天内
(4条评论)
0.0
IvanovichIvanov

Thanks for your posting job. I have read your requirements carefully and fully understood what you need. I am expert in programming using almost languages. Especially, i have a rich experience in Java, C/C+, Gambas, VC 更多

$50USD 在1天里
(0条评论)
0.0
VasylSamuliak

I have rich experience in C++ programming language, so I can help you with this project.............

$20 USD 在3天内
(0条评论)
0.0
jwum1100

This looks just like the project specs I do at school and shouldn't be a problem. I'm a 3rd year college student primarily using c++ but could potentially do python too. Can have it done pretty much whenever, let me kn 更多

$25USD 在1天里
(0条评论)
0.0