473,399 Members | 4,177 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

[Error] 'ConvertTO25' undeclared (first use in this function) it shows this error in

#include<stdio.h>
#include<stdlib.h>
#include<conio.h>

int board[25];
const noughts=1;
const crosses=2;
const border=3;
const empty=0;
const int ConvertTo25[9]={
6,7,8,
11,12,13,
16,17,18

};

void InitialiseBoard(int *board){
int Index=0;
for(Index=0; Index<25;++Index){
board[Index]=border;
}
for(Index=0; Index<9; ++Index){
board[ConvertTO25[Index]]=empty;
}
}
void PrintBoard(const int *board){
int Index=0;
printf("\nboard:\n");
for(Index=0; Index<25;++Index){
if(Index!=0 && Index%5==0){
printf("\n");
}
printf("%4d",board[Index]);
}
printf("\n");
}
int main()
{
int board[25];

InitialiseBoard(&board[0]);

PrintBoard(&board[0]);
getch();
return 0;
}
Feb 4 '16 #1
1 1194
donbock
2,426 Expert 2GB
C is case-sensitive.
ConvertTO25 is not the same thing as ConvertTo25.
Feb 4 '16 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: neo88 | last post by:
hi guys Can anyone please tell me what is wrong with this function: inline int strength(void) { int a; // tests to see what strength value the agent just attacked\defended with for (strength;...
2
by: kyung seop kim | last post by:
hi! all I updated compiler to gcc 3.4.3 in suse linux machine. I met the error message like subject. how can I fix this problem ?
2
by: PA | last post by:
Hi All, Thanks for your attention..I appreciate that. -----Problem description -----------Start---------------------- Database : DB2 UDB 8.2 on Windows 2003 Client: VB6/ADO 2.7 on Windows...
2
by: John Sims | last post by:
Hello All, Anybody out there know what this error is...I'm getting it while trying to create a partial replica from a full replica made from the design master. "The Partial Replica Wizard has...
25
by: Java Böy | last post by:
could some body help me what's happening here... thanks.. char sc = "\x31\xc0" /* xor %eax, %eax */ "\x50" /* push %eax */...
2
by: ritchie | last post by:
Hi, Just wanted to ask if anybody has any idea what i'm doing wrong. I have a function which edits a linked list. It works fine. I pass in a pointer to the list plus the value of the item to...
4
by: Peter Rothenbuecher | last post by:
Hello, when I try to compile the following code: /* This fragment of code is taken from an online tutorial */ #include<stdio.h> #include<fcntl.h> #include<stdlib.h> float bigbuff;
10
by: asnowfall | last post by:
I get following compilation error C3149: 'System::String' : cannot use this type here without a top-level '^'. Could someone explain why I get this error? here is the code... ImageFileData.h...
6
by: rwsims | last post by:
This works in firefox, not at all in ie6. I'm not getting any errors, but only the doalert() function works, not the click() function. I'm sure there's something obvious, but I'm just not seeing...
83
by: Anonymous | last post by:
Came across some code summarized as follows: char const* MyClass::errToText(int err) const { switch (err) { case 0: return "No error"; case 1: return "Not enough"; case 2: return "Too...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.