Why put void in params?

前端 未结 6 1040
别跟我提以往
别跟我提以往 2020-12-08 19:33

What\'s the reason for putting void inside of the params?

Why not just leave it blank?

void createLevel(void);

void createLevel();
6条回答
  •  死守一世寂寞
    2020-12-08 20:18

    There's no difference, this is just down to personal preference, e.g. to show yourself that when designing the function you didn't forget to give params.

提交回复
热议问题