constrain()

จำกัด ค่าระหว่างค่าต่ำสุดและสูงสุด

รูปแบบการใช้งาน

constrain ( n, low, high )

พารามิเตอร์

  • n Number: จำนวนที่ จำกัด
  • low Number: ขีด จำกัด ขั้นต่ำ
  • high Number: ขีด จำกัด สูงสุด

ค่าที่ส่งออกมา

  • Number: จำนวนข้อ จำกัด


[1]This document was generated from p5.js whose source code is available on github.