gcc - c programming error: expected specifier-qualifier-list before '{ ' -
#include <stdio.h> #include <stdlib.h> #include <math.h> typedef struct tagpoint { double x, y; } point, *ppoint; typedef struct tagsource { point location; float power; } source, *psource; typedef struct { { struct tagsource tagsource[100],random [2]; struct tagpoint}; double spl(double w, double r); double spl_total(struct tagsource *srcs, int count, struct tagpoint dest); double distance(struct tagpoint p1, struct tagpoint p2); double power(double w); int sort(struct tagsource *srcs, int count); int display(struct tagsource *srcs, int count); int main (int argc, char *argv[]) {
the error message reads:c:15: expected specifier-qualifier-list before '{' token
i tried how solve @ dead end. please help me mend this.
to to the lowest degree change:
int main (int argc, char *argv[]) ;{
to
int main (int argc, char *argv[]) {
c gcc compiler-errors
No comments:
Post a Comment