DCG for a predicate outputting a list containing a binary number and the decimal counterpart as the last element

前端 未结 0 1071
南方客
南方客 2021-01-05 07:37

Write a DCG for a predicate s that outputs lists of the form

[b₁, b₂, ... , bₙ, k]

for every integer n ≥ 0 such that each bᵢ is either 0 or 1

相关标签:
回答
  • 消灭零回复
提交回复
热议问题