首页IT科技cprogramminglanguage安卓下载(C Programming/Pointers and arrays Wikibooks, open books for an open world)

cprogramminglanguage安卓下载(C Programming/Pointers and arrays Wikibooks, open books for an open world)

时间2025-05-05 03:04:09分类IT科技浏览3978
导读:float KrazyFunction(...

float KrazyFunction( struct MyStruct *parm1, int p1size, int bb ) { int ix; //declaring an integer variable// for (ix=0; ix<p1size; ix++) { if (parm1[ix].m_aNumber == bb ) return parm1[ix].num2; } return 0.0f; }

/* ... */ struct MyStruct myArray[4]; #define MY_ARRAY_SIZE (sizeof(myArray)/sizeof(*myArray)) float v3; struct MyStruct *secondArray; int someSize; int ix; /* initialization of myArray ... */ v3 = KrazyFunction( myArray, MY_ARRAY_SIZE, 4 ); /* ... */ secondArray = calloc( someSize, sizeof(myArray) ); for (ix=0; ix<someSize; ix++) { secondArray[ix].m_aNumber = ix *2; secondArray[ix].num2 = .304 * ix * ix; }

创心域SEO版权声明:以上内容作者已申请原创保护,未经允许不得转载,侵权必究!授权事宜、对本内容有异议或投诉,敬请联系网站管理员,我们将尽快回复您,谢谢合作!

展开全文READ MORE
深度学习如何训练出好的模型