Mercurial > projects > dstress
view run/f/for_06_I.d @ 1091:9dcac8d4e97f
post DMD-0.163 review
author | thomask |
---|---|
date | Fri, 21 Jul 2006 11:15:26 +0000 |
parents | 1e6afb94ce6d |
children | b8c0195059d9 |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ Deewiant <deewiant.doesnotlike.spam@gmail.com> // @date@ 2005-08-06 // @uri@ news:dd23j9$1b6c$1@digitaldaemon.com module dstress.run.f.for_06_I; int foo(double[] arr) { size_t i = 1; int counter; for(size_t j = arr.length-1; j >= i; j--) { arr[j] = arr[j - i]; counter++; } return counter; } int main(){ double[] array; array.length = 2; if(foo(array)==1){ return 0; }else{ return 1; } }