Class: CodeforcesAPI::Object::ProblemResult
- Inherits:
-
Object
- Object
- CodeforcesAPI::Object::ProblemResult
- Defined in:
- lib/codeforces_api/object/problem_result.rb
Constant Summary collapse
- ATTRS =
[ :points, :penalty, :rejectedAttemptCount, :type, :bestSubmissionTimeSeconds, ].freeze
Instance Method Summary collapse
-
#initialize(problem_result) ⇒ ProblemResult
constructor
A new instance of ProblemResult.
Constructor Details
#initialize(problem_result) ⇒ ProblemResult
Returns a new instance of ProblemResult.
14 15 16 |
# File 'lib/codeforces_api/object/problem_result.rb', line 14 def initialize problem_result ATTRS.each { |attr| instance_variable_set("@#{attr}", problem_result[attr.to_s]) } end |