本文整理匯總了Python中term.Term.from_int方法的典型用法代碼示例。如果您正苦於以下問題:Python Term.from_int方法的具體用法?Python Term.from_int怎麽用?Python Term.from_int使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類term.Term
的用法示例。
在下文中一共展示了Term.from_int方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: print_lines_simple
# 需要導入模塊: from term import Term [as 別名]
# 或者: from term.Term import from_int [as 別名]
def print_lines_simple(asker, lines):
return asker.ask_tail(print_lines(lines, T.from_int(0), T.from_str(" ")))
示例2: reply
# 需要導入模塊: from term import Term [as 別名]
# 或者: from term.Term import from_int [as 別名]
def reply(self, *args, **kwargs):
result = super(Counter, self).reply(*args, **kwargs)
return result.add(queries(T.from_int(self.cost)))
示例3: T
# 需要導入模塊: from term import Term [as 別名]
# 或者: from term.Term import from_int [as 別名]
import convert
import representations
import properties
import updates
import outlines
import builtins
import computations
import term
import termtypes
import state
import views
import functions
import strings
from term import Term as T
k = updates.update(updates.trivial(), T.from_int(0))
d = T('test [a]', a=k)
Q = T('a question about [this]', this=k)
asker = ask.Asker(Q)
a = T('a')
b = T('b')
c = T('c')
l1 = T.from_list([a, b, c])
l2 = T.from_list([a, a, a])
l12 = lists.zip(l1, l2)
d = dictionaries.from_items(l12)
示例4: make_int_expr
# 需要導入模塊: from term import Term [as 別名]
# 或者: from term.Term import from_int [as 別名]
def make_int_expr(k):
return T(make_int_expr.head, k=T.from_int(k[0]))