Search found 2 matches

by amazingjxq
Wed Oct 15, 2008 2:53 pm
Forum: Volume 4 (400-499)
Topic: 460 - Overlapping Rectangles
Replies: 25
Views: 2631

Re: 460:I can't find what's wrong with my solution

guys,i'm really confused. What's wrong?
by amazingjxq
Sun Oct 12, 2008 1:43 pm
Forum: Volume 4 (400-499)
Topic: 460 - Overlapping Rectangles
Replies: 25
Views: 2631

460:I can't find what's wrong with my solution

#include "stdio.h" #include "math.h" #include "iostream" #include "algorithm" using namespace std; struct rect { int xll; int xur; int yll; int yur; }; struct rect overlap(struct rect r1,struct rect r2) { struct rect res={0,0,0,0}; float t1=fabs((float)(r1.xll+r1.xur)/2.0-(float)(r2.xll+r2.xur)/2.0...

Go to advanced search