No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
A programming contest, puzzle, ping pong addict.
Re:
Hello, I am not sure why, when I call my method, it goes into a continuous loop and prints out nothing. The operator - method is suppose to be able to subtract a Date object and a Date argument. I will clarify if anything needs clarifying, thanks for the help … |
|
Re:
When making overloaded template function is there a difference between template<> or template<type>. For example is there a difference between [CODE] template <class T> void dispm(T array) { cout << "called template<class T> void dispm(string array)"; } template<class T> void dispm(string array) { cout << "called template<class T> void dispm(string … |
|
Re:
Whats wrong here ? Why the code output prints some extra lines? Input:line number=n. Enter number=num.If line=4 and num=2 , the output will be.... 2 4 8 16 My code is.... [CODE]#include<iostream> #include<conio.h> using namespace std; int main() { int n,num,i,j,s=1,m; cin>>n>>num; for(i=1;i<=n;i++) { m=1; while(s<=j){ m=num*m; s++; } cout<<m; … |
|
Re:
[B]Input[/B] The first line contains the number of test cases t (1 ≤ t ≤ 5). Then t test cases follow, each test case consists of a line containing two integers n and k (0 ≤ n ≤ 100000, n < k ≤ 1018). [B]Output[/B] For each test case output … |