Sha256: 448f12318a3a32a278a61c9749397c8288b47fd671adfb4bb0983fd36ce3e50c

Contents?: true

Size: 1.43 KB

Versions: 102

Compression:

Stored size: 1.43 KB

Contents

{
  "#": [
    "The final tests of square test error conditions",
    "The expection for these tests is -1, indicating an error",
    "In these cases you should expect an error as is idiomatic for your language"
  ],
  "square": {
    "description": "returns the number of grains on the square",
    "cases": [
      {
        "description": "1",
        "input": 1,
        "expected": 1
      },
      {
        "description": "2",
        "input": 2,
        "expected": 2
      },
      {
        "description": "3",
        "input": 3,
        "expected": 4
      },
      {
        "description": "4",
        "input": 4,
        "expected": 8
      },
      {
        "description": "16",
        "input": 16,
        "expected": 32768
      },
      {
        "description": "32",
        "input": 32,
        "expected": 2147483648
      },
      {
        "description": "64",
        "input": 64,
        "expected": 9223372036854775808
      },
      {
        "description": "square 0 raises an exception",
        "input": 0,
        "expected": -1
      },
      {
        "description": "negative square raises an exception",
        "input": -1,
        "expected": -1
      },
      {
        "description": "square greater than 64 raises an exception",
        "input": 65,
        "expected": -1
      }
    ]
  },
  "total": {
    "description": "returns the total number of grains on the board",
    "expected": 18446744073709551615
  }
}

Version data entries

102 entries across 102 versions & 1 rubygems

Version Path
trackler-2.0.8.13 common/exercises/grains/canonical-data.json
trackler-2.0.8.12 common/exercises/grains/canonical-data.json
trackler-2.0.8.11 common/exercises/grains/canonical-data.json
trackler-2.0.8.10 common/exercises/grains/canonical-data.json
trackler-2.0.8.9 common/exercises/grains/canonical-data.json
trackler-2.0.8.8 common/exercises/grains/canonical-data.json
trackler-2.0.8.7 common/exercises/grains/canonical-data.json
trackler-2.0.8.6 common/exercises/grains/canonical-data.json
trackler-2.0.8.5 common/exercises/grains/canonical-data.json
trackler-2.0.8.4 common/exercises/grains/canonical-data.json
trackler-2.0.8.3 common/exercises/grains/canonical-data.json
trackler-2.0.8.2 common/exercises/grains/canonical-data.json
trackler-2.0.8.1 common/exercises/grains/canonical-data.json
trackler-2.0.7.0 common/exercises/grains/canonical-data.json
trackler-2.0.6.44 common/exercises/grains/canonical-data.json
trackler-2.0.6.43 common/exercises/grains/canonical-data.json
trackler-2.0.6.42 common/exercises/grains/canonical-data.json
trackler-2.0.6.41 common/exercises/grains/canonical-data.json
trackler-2.0.6.40 common/exercises/grains/canonical-data.json
trackler-2.0.6.39 common/exercises/grains/canonical-data.json