I'm trying to code a program that categorized a series to be one of the following for example:

  1. "demo" ; "abc" - are both hard ascending series.
  2. "aabc" ; "aa" ; "zz" - are an ascending series.
  3. "zzabcd" - is a non-ordered series.

I wrote the following:

#include‬ <stdio.h>
int main()
{
int c1,c2;
int ascend=0;
int descend=0;
int fixed = 0;
c1=getchar();
c2=getchar();
putchar(c1);
while ((c1!= EOF) || (c2!=EOF))
}
putchar(c2(;
if (c1<c2(
ascend=1;
else if (c1>c2(
descend=1;
else if (c1==c2(
fixed =1;
c1=c2;
c2=getchar(); 
{ 
printf("\n%d\n%d\n%d" ,ascend,descend,fixed); 

can someone help me arrange it and make it work ? It should work with linux, but nothing helps it just don't work.

That code wont compile. Do you have a working example (that was copied incorrectly) or are you asking how to get the current example to compile?