[Dev-C++] copying part of a string to another string?
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Calvin M. <cm...@pg...> - 2001-01-15 03:20:20
|
Hello, I am trying to work an assignment for school, and I am having trouble
copying part of a string to another string. the string is a area code that
includes the () and I am trying to get numbers only from it so I can turn
them into a int. The code I have tried is below. temp currently holds the
areacode withe the ().
Any input would be greatly appriceated.
Calvin
for(i=1,x=0;i<4;i++)
{
*areaptr = temp[i];
areaptr++;
}
|