Hi everybody.
Here is my suggestion:
-all types you need is int and double
-for solving here is some info:
You must compute the arithmetic mean (AM) for the spendings of the students. And there are 3 cases:
1. If the AM is something like ddd.005 then you must compute the minimum exchange sums for ...
Search found 8 matches
- Wed Aug 24, 2005 12:45 am
- Forum: Volume 101 (10100-10199)
- Topic: 10127 - Ones
- Replies: 32
- Views: 18085
- Sat Apr 16, 2005 11:12 am
- Forum: Volume 104 (10400-10499)
- Topic: 10400 - Game Show Math
- Replies: 32
- Views: 23210
Hi Cruzer
I've solved this problem using optimized Backtracking.
Optimization in this case refers to following: if you have passed through a partial solution once at step k in Back() (I mean a target number, not the final target number), which is in the range (-32000..32000), and the algo came back to this ...
Optimization in this case refers to following: if you have passed through a partial solution once at step k in Back() (I mean a target number, not the final target number), which is in the range (-32000..32000), and the algo came back to this ...
- Sat Apr 16, 2005 10:52 am
- Forum: Volume 104 (10400-10499)
- Topic: 10422 - Knights in FEN
- Replies: 49
- Views: 25722
- Wed Apr 13, 2005 2:36 pm
- Forum: Volume 104 (10400-10499)
- Topic: 10422 - Knights in FEN
- Replies: 49
- Views: 25722
- Tue Apr 12, 2005 11:11 pm
- Forum: Volume 104 (10400-10499)
- Topic: 10422 - Knights in FEN
- Replies: 49
- Views: 25722
10422
I'm stuck . I don't know what's wrong. I've solved this problem with DFS first, then with BFS. WA for both...
PLEASE give me some inputs & outputs.
These are inputs & outputs obtained with my code:
input
4
01011
110 1
01110
01010
00100
10110
01 11
10111
01001
00000
11111
01111
00 11
00001
00000 ...
PLEASE give me some inputs & outputs.
These are inputs & outputs obtained with my code:
input
4
01011
110 1
01110
01010
00100
10110
01 11
10111
01001
00000
11111
01111
00 11
00001
00000 ...
- Sat Apr 09, 2005 9:37 am
- Forum: Volume 100 (10000-10099)
- Topic: 10011 - Where Can You Hide?
- Replies: 58
- Views: 19146
- Mon Aug 18, 2003 2:35 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10014 - Simple calculations
- Replies: 34
- Views: 13009
- Wed Aug 13, 2003 6:06 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10014 - Simple calculations
- Replies: 34
- Views: 13009
10014
Hi...
10014...
I really don't know what's wrong with my code! Will you tell me??
Here is my code in C:
/*
* autor: Lamasanu Ion, July 2003
* ACM Contest training
*
* Simple calculations 10014
*/
#include <stdio.h>
int main(void)
{
int n, i;
double a0, a1, an1, Ci, S=0;
scanf("%d%lf%lf ...
10014...
I really don't know what's wrong with my code! Will you tell me??
Here is my code in C:
/*
* autor: Lamasanu Ion, July 2003
* ACM Contest training
*
* Simple calculations 10014
*/
#include <stdio.h>
int main(void)
{
int n, i;
double a0, a1, an1, Ci, S=0;
scanf("%d%lf%lf ...