# D&D.Sci Long War: Defender of Data-mocracy

*This is an entry in the 'Dungeons & Data Science' series, a set of puzzles where players are given a dataset to analyze and an objective to pursue using information from that dataset. *

**STORY (skippable)**
=====================

You have the excellent fortune to live under the governance of The People's Glorious Free Democratic Republic of Earth, giving you a Glorious life of Freedom and Democracy.

Sadly, your cherished values of Democracy and Freedom are under attack by...THE ALIEN MENACE!

![](https://39669.cdn.cke-cs.com/rQvD3VnunXZu34m86e5f/images/249bc16b2cd35d11e6949b277993f7f7827ac3892742b298.png)

The typical reaction of an Alien Menace to hearing about Freedom and Democracy.  (Generated using OpenArt SDXL).

Faced with the desperate need to defend Freedom and Democracy from The Alien Menace, The People's Glorious Free Democratic Republic of Earth has been forced to redirect most of its resources into the Glorious Free People's Democratic War Against The Alien Menace.  

You haven't really paid much attention to the war, to be honest.  Yes, you're sure it's Glorious and Free - oh, and Democratic too! - but mostly you've been studying Data Science and employing it in your Assigned Occupation as a Category Four Data Drone.

But you've grown tired of the Class Eight Habitation Module that you've been Democratically Allocated, and of your life as a Category Four Data Drone.  And in order to have a voice in civic affairs (not to mention the chance to live somewhere nicer), you've enlisted with the Democratic People's Glorious Free Army in their Free Glorious People's Democratic War Against The Alien Menace.

![Most of the enlistment posters look like this.  (The other half focus on how joining the People's Glorious Free Democratic Army will make you more attractive to [YOUR GENDER OF CHOICE]](https://39669.cdn.cke-cs.com/rQvD3VnunXZu34m86e5f/images/e3fa67f2abcce8daf6fc97cc9082f9c1f41c9403b95f3301.png)

Half of the enlistment posters look like this.  The other half focus on how joining the Democratic People's Glorious Free Army will grant you voting rights, a better Habitation Module, and make you more attractive to whichever gender you happen to prefer.  (Generated using OpenArt SDXL).

You enlisted with the Tenth Democratic Free Glorious People's Mobilization, and were assigned to a training battalion under Sergeant Rico.  

He's taught you a great deal about armed combat, unarmed combat, and how many pushups you can be forced to do before your arms give out.

![](https://39669.cdn.cke-cs.com/rQvD3VnunXZu34m86e5f/images/ff5bd1809e048ea019b87f309ff1bb1cf6aa0a3b1d92c2b9.png)

Sgt. Rico in an unusually good mood. (Generated using OpenArt SDXL).

You're sure the People's Glorious Free Democratic Army knows more than you about war in general.  But you feel like the logistical and troop-deployment decisions being made are suboptimal, and you've been on the lookout for ways to employ your knowledge of Data Science to improve them.

So when you got your hands on a [dataset](https://raw.githubusercontent.com/aphyer1992/dndsci_longwar/main/dndsci_long_war_data.csv) of past deployments against the Alien Menace, you brought up with Sgt. Rico that you think you can use that to improve outcomes by selecting the right weapons loadout for each squad to bring.

In retrospect, when he leaned into your face and screamed: 'So you think you can do better, recruit?', that might have been intended as a rhetorical question, and you probably shouldn't have said yes.

Now you've been assigned to join a squad defending against an attack by the Alien Menace.  At least he's agreed to let you choose how many soldiers to bring and how to equip them based on the [data](https://raw.githubusercontent.com/aphyer1992/dndsci_longwar/main/dndsci_long_war_data.csv) you collated (though you do rather suspect he's hoping the Alien Menace will eat you).

But with Data Science on your side, you're sure you can select a team that'll win the engagement, and hopefully he'll be more willing to listen to you after that.  (Especially if you demonstrate that you can do it reliably and efficiently, without sending too large a squad that would draw manpower from other engagements).

For Glory! For The People!  For Freedom!  For Democracy! For The People's Glorious Free Democratic Republic of Earth!  And for being allocated a larger and more pleasant Habitation Module and a higher-quality Nutrition Allotment!

[**DATA**](https://raw.githubusercontent.com/aphyer1992/dndsci_longwar/main/dndsci_long_war_data.csv) **& OBJECTIVES**
======================================================================================================================

*   You've been assigned to repel an alien attack.  The alien attack contains:
    *   3 Arachnoid Abominations
    *   2 Chitinous Crawlers
    *   7 Swarming Scarabs
    *   3 Towering Tyrants
    *   1 Voracious Venompede
*   You need to select a squad of soldiers to bring with you.  You may bring up to 10 soldiers, with any combination of the following weapons:
    *   Antimatter Artillery
    *   Fusion Flamethrower 
    *   Gluon Grenades
    *   Laser Lance
    *   Macross Minigun
    *   Pulse Phaser
    *   Rail Rifle
    *   Thermo-Torpedos
*   So you could bring 10 soldiers all with Antimatter Artillery.  Or you could bring 1 with a Fusion Flamethrower, 1 with Gluon Grenades, and leave the other 8 spots blank.
*   You are one of these soldiers - you've been through basic training, and are mechanically identical to the other soldiers.
*   You have two objectives:
    *   Survive (thanks to modern medical technology, this will be reliably accomplished if the battle is a win, and reliably not accomplished if the battle is a loss).
    *   Impress your superiors by bringing as few soldiers with you as possible.
    *   The leaderboard will track how well you've done relative to random/best play at the # of soldiers you chose to bring.  You'll have to decide how important your standing/reduced risk of appearing like a coward to your superiors is, relative to your chance-of-being-eaten-tomorrow.
*   To help you with this, you have a [dataset](https://raw.githubusercontent.com/aphyer1992/dndsci_longwar/main/dndsci_long_war_data.csv) of past engagements with The Alien Menace.  Each row is a single skirmish, the number of Aliens of each type that were present, the number of soldiers with each weapon that were sent, and the outcome of that battle.

I'll aim to post the ruleset and results on May 6th (giving one week and both weekends for players).  **EDIT: Some people wanted extensions, and some answers have still been filtering in, I'll be aiming to post on the 13th to give an extra week. ** If you find yourself wanting extra time, comment below and I can push this deadline back.

As usual, working together is allowed, but for the sake of anyone who wants to work alone, **please spoiler parts of your answers  that contain information or questions about the dataset.  **To spoiler answers on a PC, type a '>' followed by a '!' at the start of a line to open a spoiler block - to spoiler answers on a mobile, type a ':::spoiler' at the start of a line and then a ':::' at the end to spoiler the line.