Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
special_materials = { "shards": 0, "fragments": 0, "motes": 0 } junk_materials = {} flag = False while not flag: line = input() materials = line.split() for i in range(0, len(materials), 2): quantity = int(materials[i]) material = materials[i + 1].lower() if material in special_materials: special_materials[material] += quantity if special_materials[material] >= 250: special_materials[material] -= 250 flag = True if material == "shards": print(f"Shadowmourne obtained!") if material == "fragments": print(f"Valanyr obtained!") if material == "motes": print(f"Dragonwrath obtained!") break else: if material in junk_materials: junk_materials[material] += quantity else: junk_materials[material] = quantity for material, count in special_materials.items(): print(f"{material}: {count}") for material, count in junk_materials.items(): print(f"{material}: {count}")
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)