source:
CIVL/examples/arithmetic/sqrtBad1.cvl@
bb03188
| Last change on this file since bb03188 was ea777aa, checked in by , 3 years ago | |
|---|---|
|
|
| File size: 171 bytes | |
| Rev | Line | |
|---|---|---|
| [3ff27cf] | 1 | #include <civlc.cvh> |
| [869af89] | 2 | #include <math.h> |
| 3 | #include <assert.h> | |
| 4 | ||
| 5 | $input double x; | |
| [3ff27cf] | 6 | $assume(x >= 0.0); |
| [869af89] | 7 | |
| 8 | int main() { | |
| 9 | double y = sqrt(x) + 1; | |
| 10 | ||
| 11 | assert(y >= 1.1); | |
| 12 | return 0; | |
| 13 | } |
Note:
See TracBrowser
for help on using the repository browser.
