Search found 9 matches

by enamsustcse
Thu Nov 06, 2014 1:24 am
Forum: Volume 128 (12800-12899)
Topic: 12832 - Chicken Lover
Replies: 1
Views: 877

Re: 12832 - Chicken Lover

Why fgets causes run time error for this problem?


/**
* H:\Dropbox\Code\UVa\12832 - Chicken Lover.cpp
*
* Created on: 2014-11-04-18.56.35, Tuesday
* Author: Enamul Hassan
* Verdict: SOLVED
**/

#include <bits/stdc++.h>
//#define _ ios_base::sync_with_stdio(0);cin.tie(0);


#define sz 100005 ...
by enamsustcse
Tue Oct 08, 2013 5:37 pm
Forum: Volume 1 (100-199)
Topic: 146 - ID Codes
Replies: 35
Views: 10064

Re:

UFP2161 wrote:cxxoc --> occxx
This test case was very helpful for me, Thanks to all belonging to this problem :)
by enamsustcse
Tue Feb 05, 2013 10:05 am
Forum: Volume 4 (400-499)
Topic: 469 - Wetlands of Florida
Replies: 63
Views: 32356

Re: Wetlands Of Florida - 469

brianfry713 wrote:The outputs of two consecutive cases will be separated by a blank line. Don't print an extra blank line at the end.
Thanks a lot once more... :) :) :)
by enamsustcse
Sun Feb 03, 2013 2:52 pm
Forum: Volume 4 (400-499)
Topic: 469 - Wetlands of Florida
Replies: 63
Views: 32356

Re: Wetlands Of Florida - 469

I am getting WA!
please, help me.... :x :x :x

here is m code:
#include <iostream>
#include <queue>
#include <cctype>
#include <cstdio>
#include <cstdlib>
#include <cstring>
using namespace std;
int bfs (int x, int y);
string graph[99];
string ex[99];
int n,m;
int main()
{
int t, caseno=1,x,y, i ...
by enamsustcse
Sat Jan 19, 2013 12:02 am
Forum: Volume 100 (10000-10099)
Topic: 10062 - Tell me the frequencies!
Replies: 235
Views: 69560

Re: 10062 - Tell Me the Frequencies!

#include <stdio.h>
#include <string.h>

int main()
{
int len, cnt,i,j,x,max, maxpos;
int list[150];
int print[150][2];
char input[5000];
bool flag = false;
while(gets(input))
{
if(flag) printf("\n");
flag = true;
cnt = 0;
max = 1;
len = strlen(input);

for (i=32; i<129; i++)
{
list[i ...
by enamsustcse
Fri Jan 18, 2013 9:26 pm
Forum: Volume 101 (10100-10199)
Topic: 10189 - Minesweeper
Replies: 418
Views: 124831

10189 - Minesweeper

#include <stdio.h>
#define sz 150

int graph[sz][sz];
char input[sz][sz];

int main()
{
int caseno=1, i, j, k, m, n, p, q;
scanf("%d %d", &m, &n);
while(m&&n)
{
for (i=0; i<m; i++)
for (j=0; j<n; j++)
graph [j] = 0;

for (i=0; i<m; i++)
{
getchar();
for (j=0; j<n; j++)
scanf("%c", &input ...
by enamsustcse
Fri Jan 18, 2013 9:15 pm
Forum: Volume 104 (10400-10499)
Topic: 10424 - Love Calculator
Replies: 137
Views: 59845

Re: 10424 - Love Calculator

brianfry713 wrote:Input:

Code: Select all

Love
Calculator
AC output:

Code: Select all

77.78 %
Thanx boss. This test case helped me to find the bug in my code. there was a silly mistake in reducing the number to 1 digit.
Thanks a lot!!!
:)
by enamsustcse
Sat May 19, 2012 12:48 am
Forum: Volume 5 (500-599)
Topic: 591 - Box of Bricks
Replies: 80
Views: 24943

Re: 591-Box of bricks

Thanx a lot,,
I have just mistaken it for last several attepmts...
but now.. :D
by enamsustcse
Fri May 04, 2012 9:52 pm
Forum: Volume 104 (10400-10499)
Topic: 10424 - Love Calculator
Replies: 137
Views: 59845

Re: 10424 - Love Calculator

#include <stdio.h>
#include <string.h>


int main()
{
int i, len1, len2, sum1, sum2, v, x, y, z, flag;
double ratio, s1, s2;
char a[30], b[30];

while(gets(a) && gets(b))
{
flag = 1;
sum1 = sum2 = 0;
len1 = strlen(a);
len2 = strlen(b);

for (i = 0; i < len1; ++i)
{
if(a >= 'a' && a <= 'z ...

Go to advanced search