File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -84,18 +84,18 @@ framework.
8484
8585To use it just import the parser:
8686
87- >>> from dice_notation.parser import DiceParser
87+ from dice_notation.parser import DiceParser
8888
8989And then use it to parse a dice notation expression:
9090
91- >>> parser = DiceParser()
92- >>> dice = parser.parse(' 1d6+2' )
91+ parser = DiceParser()
92+ dice = parser.parse('1d6+2')
9393
9494The result can be accessed just by calling the 'roll' method as many times as
9595needed, which will generate a new random value each time it is called.
9696
97- >>> print (dice.roll())
98- >>> print (dice.roll())
97+ print(dice.roll())
98+ print(dice.roll())
9999
100100Collaborate
101101-----------
Original file line number Diff line number Diff line change 44
55To use the parser just import it:
66
7- >>> from dice_notation.parser import DiceParser
7+ from dice_notation.parser import DiceParser
88
99And then parse a dice notation expression:
1010
11- >>> parser = DiceParser()
12- >>> dice = parser.parse(' 1d6+2' )
11+ parser = DiceParser()
12+ dice = parser.parse('1d6+2')
1313
1414The result can be accessed just by calling the 'roll' method as many times as
1515needed, which will generate a new random value each time it is called.
1616
17- >>> print (dice.roll())
18- >>> print (dice.roll())
17+ print(dice.roll())
18+ print(dice.roll())
You can’t perform that action at this time.
0 commit comments