7 Years
Discussion Span
Last Post by leegeorg07

1) explain what you mean
2) give us some code, we will only help when you put some effort in

Yes. Please give us some code so that we can execute it. Thank you!


Concepts: This game will give you the opportunity to work on your decision making and looping skills.

The Emperor of Rome is in desperate need of a commander to lead an attack against the Germanian Hordes. You approach the Emperor and tell him that you are willing to sacrifice your life for your country. The Emperor does not know who you are or what your name is, so he asks you.

Your army consists of 50 Archers, 25 Catapults, and 100 Swordsmen. Your scouts have told you that the Germanian army has anywhere from 20-70 Archers, 10-50 Catapults, and 50-150 Swordsmen.

You want more accurate numbers before you go into battle so you send the scouts out again and not to come back until they know the exact number of Archers, Catapults and Swordsmen the Germanian’s have.

The commander now has the option to send the Archers, the Catapults and the Swordsmen to the battle field. You do not have to send them all to engage in the battle, but it may be to your advantage to do so. Once the commander has sent the army to the battle field, they await the commander’s order to engage into combat.

The rules of the battle are as followed:
1) Each Catapult kills 2 Archers
2) Each Swordsmen kills 1 catapult
3) Each Archer kills 3 Swordsmen

As a programmer, you need to make sure that the commander never has less than 0 of each of the Archers, Catapults and Swordsmen.

Once the battle is over you send one of your scouts to the battle field to report back the damage that was done. Based upon his report, you will know if you were victorious, if there are no Germanian Archers, Catapults, or Swordsmen left, or if you were defeated, there are no Roman Archers, Catapults, or Swordsmen left.

help !!!

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.