This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body> | |
<input id="x"> | |
<div id="concat_link">a</div> | |
<script> | |
add = "p=1T14183534162201601I&utm_campaign=FPVist&utm_content=3312" | |
link = "https://www.banggood.com/Anniversary-Special-Edition-Martian-215-215mm-Carbon-Fiber-FPV-Racing-Frame-Kit-136g-p-1180757.html?rmmds=search&cur_warehouse=CN" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Based on https://github.com/j2kun/tex-convert-delimiters/blob/master/convert-delimiters.py | |
# A response to https://jeremykun.com/2019/04/20/a-working-mathematicians-guide-to-parsing/ | |
import sys | |
from lark import Lark, Transformer | |
lark = Lark(r''' | |
tex: (mathmode_offset | mathmode_inline | TEXT)+ | |
mathmode_offset: OFFSETDOLLAR TEXT+ OFFSETDOLLAR | OFFSETOPEN TEXT+ OFFSETCLOSE |
NewerOlder