8 kyu

Grasshopper - Terminal game combat function

13,578 of 41,031rom4eg

Description:

Create a combat function that takes the player's current health and the amount of damage received, and returns the player's new health. Health can't be less than 0.

Fundamentals

Stats:

CreatedJan 3, 2017
PublishedJan 3, 2017
Warriors Trained46602
Total Skips1945
Total Code Submissions70656
Total Times Completed41031
JavaScript Completions13578
Ruby Completions967
Python Completions12401
Crystal Completions44
Rust Completions1315
C# Completions2530
Go Completions3013
C++ Completions5853
PHP Completions1311
Haskell Completions309
CoffeeScript Completions26
Racket Completions56
C Completions319
Java Completions847
Groovy Completions21
Total Stars172
% of votes with a positive feedback rating91% of 3823
Total "Very Satisfied" Votes3233
Total "Somewhat Satisfied" Votes508
Total "Not Satisfied" Votes82
Total Rank Assessments115
Average Assessed Rank
7 kyu
Highest Assessed Rank
7 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • rom4eg Avatar
  • strangelittlemonkey Avatar
  • donaldsebleung Avatar
  • kazk Avatar
  • LesnyRumcajs Avatar
  • adrian.eyre Avatar
  • nekokat Avatar
  • Voile Avatar
  • Madjosz Avatar
  • mitron6 Avatar
  • Souzooka Avatar
  • rowcased Avatar
  • Hades2004 Avatar
  • Mooaholic Avatar
  • cliffstamp Avatar
  • ejini战神 Avatar
  • rge123 Avatar
  • FranzMartyn Avatar
  • KayleighWasTaken Avatar
  • bprinc Avatar
Ad