case 2:{ if(h==-1) nodata(); else output(h);break; }

学习 时间:2026-09-28 16:50:31 阅读:4546
case 2:{ if(h==-1) nodata(); else output(h);break; }:\vc++\lianbiao.cpp(154) :error C2664:'output' :cannot convert parameter 1 from 'int' to 'struct node *'Conversion from integral type to pointer type requires reinterpret_cast,C-style cast or function-style cast怎么改?

最佳回答

彩色的小兔子

粗犷的大碗

2026-09-28 16:50:31

你的output里肯定是要打印一个结构体node*的,但是你把一个整型值比方说是a副职给他了,可以这么改用到a的地方改成 (struct node *)a

最新回答共有2条回答

  • 迷路的蛋挞
    回复
    2026-09-28 16:50:31

    你的output里肯定是要打印一个结构体node*的,但是你把一个整型值比方说是a副职给他了,可以这么改用到a的地方改成 (struct node *)a

上一篇 万户飞天 读后感读《千年梦圆在今朝》的读后感,或是读了万户飞天的故事的读后感也可!谢谢!

下一篇 Thomas is crying.the teacher asks him