Please upvote me. Need karma points to ask questions. Thanks !
Wait, what?
You asked a Q stating that you need karma to ask a Q? Am I missing something?
EDIT- And whats this “converted to Q X mins ago” thing? Can anyone explain about that? I would appreciate it!
How did you manage to ask question if you didn’t have karma points ?
Is this 'cause of new system ? (bug or something)
My sentiments exactly!!
You probably tried too hard on the March challenge and now you seem confused lol.
I think he posted that (the current question) as an answer and someone upvoted him. 1 Hour ago he clicked on convert answer to question and hence the result
click on “more” beside the delete button in this answer and there will be an option to convert answer to question. That’s what he did!
you can even convert comments to answers like this
Thanks for answering
So this is the question for which you needed karma points. This should be marked as community wiki
XD Lmao…
need 3 karmas please upvote well i joined codechef to ask questions.
Off you go!
how do i gain karma points to ask question ?
should i ask here?
maybe if someone sees this please solve this.
the question is from beginners section FLOW007 - reversing the number.
the code goes:
#include<stdio.h>
#include<math.h>
int main()
{
int t,num,temp,n,i,j,sum;
scanf("%d",&t);// no of test cases
while(t>0){
scanf("%d",&num);// asking the number
temp=num;
n=0;
while(temp>0){
temp=temp/10;
n++;// counting no of digits in the number given
}
int a[n];
sum=0;
for(i=0;i<n;i++){
a[i]=num%10;// storing each digit in an array cell
num=num/10;
sum=sum + a[i]*pow(10,(n-(1+i)));//summing by expanding
}
printf("%d\n",sum);
t–;
}return 0;
}
i am getting correct reversed number for all numbers except 3-digit numbers.
please solve someone.
thanks
#include<stdio.h>
#include<math.h>
int main()
{
int t,num,temp,n,i,j,sum;
scanf("%d",&t);// no of test cases
while(t>0)
{
scanf("%d",&num);// asking the number
temp=num;
n=0;
while(temp> 0)
{
temp=temp/10;
n++;// counting no of digits in the number given
}
int a[n];
sum=0; for(i=0;i< n;i++)
{
a[i]=num%10;// storing each digit in an array cell
num=num/10;
sum=sum + a[i]*pow(10,(n-(1+i)));//summing by expanding
}
printf("%d\n",sum);
t–;
}
return 0;
}
What are you saying? Your code passed all test cases. Copy-paste it and try again. See here.
You have to help other guys first by answering their doubts! If someone satisfied with you answer or your answer cover all aspect of question then you will definitely be up-voted and your karma points will increased. So in-spite of begging karma points, try to help other ones…!
i don’t have sufficient karmas to ask any question… please upvote .
me need karma points,please help me.i dnt why i am downvoted,huh.
please upvote me i need to ask some questions.