You're viewing version 1.2.0 of inc. The latest stable version of Clojure Core is 1.3.0.
1.2.0 Arrow_down_16x16
  • (inc x)
Returns a number one greater than num.

1 Example top

  • user=> (inc 1)
    2
    
    user=> (inc 1.0)
    2.0
    
    user=> (inc 1/2)
    3/2
    
    user=> (inc -1)
    0
    
Log in to add / edit an example.

See Also top

Log in to add a see also.

Comments top

1 comment(s) for inc.

Is the documentation suppose to be: "Returns a number one greater than x." ? If not what is num?

Log in to add a comment.