(Visual Studio) Appears only on my computer while using Visual Studio.

Asked 2 years ago, Updated 2 years ago, 48 views

char *a[] = { "Hong Gil-dong", "Kim Gil-dong", "Lee Gil-dong", "Park Gil-dong", "Choi Gil-dong"};

All the other computers up there are working fine, but strangely, I... "Hong Gil-dong", "Kim Gil-dong", "Lee Gil-dong", "Park Gil-dong", "Choi Gil-dong" were all underlined Cannot initialize an entity in the form "char*" using a value in the form "const char*". What's the problem? Did I install it wrong?

c c++ visual-studio

2022-09-22 08:34

1 Answers

Is the code a .cpp extension on another computer, but is it a .c extension on your computer?

(Source: https://social.msdn.microsoft.com/Forums/vstudio/ko-KR/67678907-d581-4595-94c9-b03259c04b62/argument-of-type-const-char-is-incompatible-with-parameter-of-type-char?forum=vcgeneral)


2022-09-22 08:34

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.