QuestionAnswer class

Represents a question and its corresponding solution.

Constructors

QuestionAnswer({required String question, required int solution})
Constructor for creating a QuestionAnswer instance.
QuestionAnswer.fromJson(Map<String, dynamic> json)
Factory constructor for creating a QuestionAnswer instance from a JSON map.
factory

Properties

hashCode int
The hash code for this object.
read-onlyinherited
question String
The question text.
read / write
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
solution int
The solution to the question.
read / write

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts the QuestionAnswer object to a JSON map.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited