Subject:
|
Re: HELP!!Arrays in IC
|
Newsgroups:
|
lugnet.robotics.handyboard
|
Date:
|
Sat, 12 May 2001 04:58:03 GMT
|
Reply-To:
|
burkharc@bvsdNOMORESPAM.k12.co.us
|
Viewed:
|
1436 times
|
| |
| |
What version of IC are you using? I know the free version doesn't support
arrays (at least I don't think so).
Sachin Kothawade wrote:
> HI
> I have been trying to use arrays in Interactive C with the handybaord.
> I have to read from analog inputs 0,1,2 and 3 of the handybaord and put
> those values in an array.
> so I had written:
>
> int v0=analog(0);
> int v1=analog(1);
> int v2=analog(2);
> int v3=analog(3);
> int x[4];
> int x[]= {v0,v1,v2,v3};
>
> but when I try to download the file into HB, it gives me a syntax error
> around the line in which I am assigning values to my array elements i.e. the
> last line in the code above..if I change the last line to
> int x{}= {1,2,3,4}; then it works fine...now that is kinda weird..that I
> cannot assign variables as array elements??
>
> Any help would be greatly appreciated..
> Thanks
> Sach
|
|
Message has 1 Reply:
Message is in Reply To:
| | HELP!!Arrays in IC
|
| HI I have been trying to use arrays in Interactive C with the handybaord. I have to read from analog inputs 0,1,2 and 3 of the handybaord and put those values in an array. so I had written: int v0=analog(0); int v1=analog(1); int v2=analog(2); int (...) (24 years ago, 9-May-01, to lugnet.robotics.handyboard)
|
4 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|