Search found 2 matches

by shiv
Tue May 03, 2011 8:12 pm
Forum: Volume 3 (300-399)
Topic: 343 - What Base Is This?
Replies: 72
Views: 28334

Re: 343(What Base is This?)

this gets me a WA, can anyone please help ???
#include<stdio.h>
#include<math.h>
#include<string.h>

int findMinBase(char x[])
{
int mb=2,b,i;
for(i=0;x ;i++)
{

if(x >=65)
b=x -54;
else b=x -47;
if(b>mb)mb=b;
}
return mb;
}
int toDec(char x[],int base)
{
int i=strlen(x)-1;
int sum=0,j ...
by shiv
Mon May 02, 2011 10:12 pm
Forum: Volume 102 (10200-10299)
Topic: 10229 - Modular Fibonacci
Replies: 53
Views: 26211

Re: 10229 - Modular Fibonacci

i have tried this code of mine with all inputs/outputs (those posted on forum also)and it returned the correct answer, still this gives WA...please help..
#include<stdio.h>
#include<math.h>
long long M[2][2];
long long A[2][2];
long long C[2][2];

void matMul(long long n,long long m);
void ...

Go to advanced search