Regular Expressions 101

divide a dice roll string into the number of dice, the dices sides and a constant

Open Workspace
  • Python
  • Match
0

Regular Expression

r"
(?P<num_dice>\d+)[dwDW](?P<die_size>\d+)(?P<modifier>[\+\-]\d+)?
"
g

Description

No description provided.

Submitted by Anonymous