题解 | #嵌入式宏空间坐标数量#
嵌入式宏空间坐标数量
https://www.nowcoder.com/practice/d39d14aa884f490a987854fbc5248b7e
/**
* struct Point {
* int x;
* int y;
* };
*/
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
*
* @param point Point类 上方struct仅为二维空间点类示例,题中为多维空间的点类
* @return int整型
*/
#define length(point) (sizeof(point)/sizeof(typeof(point.x)))
int define_count(struct Point point ) {
// write code here
return length(point);
}
基恩士成长空间 421人发布
