Example #1
0
wxPlatform& wxPlatform::ElseIfNot(int platform, long value)
{
    if (!Is(platform))
        m_longValue = value;
    return *this;
}
Example #2
0
wxPlatform& wxPlatform::ElseIfNot(int platform, double value)
{
    if (!Is(platform))
        m_doubleValue = value;
    return *this;
}
Example #3
0
int main()
{
	int i,j,mi,ma;
	char *cc=a;
	FILE *fin  = fopen ("calfflac.in", "r");
    FILE *fout = fopen ("calfflac.out", "w+");
	while((fgets(cc,100,fin)!=0))
	{
		while(*cc)
		{
			cc++;
		}
	}
	for(i=0,j=0;a[i]!='\0';i++)
	{
		if(!(a[i]>='A'&&a[i]<='Z'||a[i]>='a'&&a[i]<='z'))
			continue;
		tar[j]=a[i]&0xdf;
		j++;
	}
	point=j;
	tar[j]='Z'+1;
	tot=point+j+2;
	tar[tot-1]='\0';
	for(i=0,j=tot-2;i<point;i++,j--)
	{
		tar[j]=tar[i];
	}
	Suffix_Array_Build();
	Height_Array_Build();
	max=1;
	start=1;
	for(i=1;i<tot;i++)
	{
		if(height[i]>max)
		{
			if(sa[i]>sa[i-1])
			{
				mi=sa[i-1];
				ma=sa[i];
			}
			else
			{
				mi=sa[i];
				ma=sa[i-1];
			}
			if(mi<point&&ma>point&&Is(mi,mi+height[i]-1))
			{
				max=height[i];
				start=mi;
			}
		}
		else if(height[i]==max)
		{
			if(sa[i]>sa[i-1])
			{
				mi=sa[i-1];
				ma=sa[i];
			}
			else
			{
				mi=sa[i];
				ma=sa[i-1];
			}
			if(mi<point&&ma>point&&mi<start&&Is(mi,mi+height[i]-1))
				start=mi;
		}
	}
	fprintf(fout,"%d\n",max);
	i=0;
	j=0;
	while(j<start)
	{
		if(a[i]>='A'&&a[i]<='Z'||a[i]>='a'&&a[i]<='z')
			j++;
		i++;
	}
	while(!(a[i]>='A'&&a[i]<='Z'||a[i]>='a'&&a[i]<='z'))
		i++;
	while(max>0)
	{
		fprintf(fout,"%c",a[i]);
		if(a[i]>='A'&&a[i]<='Z'||a[i]>='a'&&a[i]<='z')
			max--;
		i++;
	}
	fprintf(fout,"\n");
	return 0;
}