Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.programming > #14342
| From | Richard Heathfield <rjh@cpax.org.uk> |
|---|---|
| Newsgroups | comp.programming |
| Subject | Re: Problem C++ gas tank refuel |
| Date | 2021-12-17 10:17 +0000 |
| Organization | Fix this later |
| Message-ID | <spho4h$qci$1@dont-email.me> (permalink) |
| References | <8fd306f3-1cdc-439b-a82c-458f9b926418n@googlegroups.com> |
On 14/12/2021 04:54, Darioes wrote: > Hi guys, > > > > Im programing a new exerciese that i need to do for a college project, in C++. > > > > That project consists in implementing an algorithm that just goes the minimal ways, not like Dijkstra’s algorithm but something similar: You are have a car, that needs to go from France to Corea and you need to refil your gas tank . You need to pick the minimal ways so that the car's fuel tank is as low as possible. Step 1: Using a permuting algorithm such as Heap's algorithm <https://en.wikipedia.org/wiki/Heap%27s_algorithm> evaluate the essential tank size required for each possible route, keeping track of the minimum as you go. Step 2: print the answer. -- Richard Heathfield Email: rjh at cpax dot org dot uk "Usenet is a strange place" - dmr 29 July 1999 Sig line 4 vacant - apply within
Back to comp.programming | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Problem C++ gas tank refuel Darioes <darioes078@gmail.com> - 2021-12-13 20:54 -0800
Re: Problem C++ gas tank refuel Julio Di Egidio <julio@diegidio.name> - 2021-12-14 23:43 -0800
Re: Problem C++ gas tank refuel Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-12-15 12:59 +0000
Re: Problem C++ gas tank refuel Julio Di Egidio <julio@diegidio.name> - 2021-12-15 10:34 -0800
Re: Problem C++ gas tank refuel Richard Heathfield <rjh@cpax.org.uk> - 2021-12-17 10:17 +0000
Re: Problem C++ gas tank refuel Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-12-20 16:10 -0800
Re: Problem C++ gas tank refuel Tim Rentsch <tr.17687@z991.linuxsc.com> - 2021-12-21 08:55 -0800
csiph-web