If we shouldn't use recursion at it uses internal stack, then I hope we can
use Morris tree traversal and use a counter to find the 5th max.
On Fri, Jan 21, 2011 at 11:19 PM, juver++ avpostni...@gmail.com wrote:
@above yes, posted solution needs parent links.
Another solution is to process
CALL FOR PAPERS
and
Call For Workshop/Session Proposals
EEE'11
The 2011 International Conference on e-Learning,
e-Business, Enterprise Information Systems,
hello..
Qs:- Given an Array of contain elements range from 1 to 9 find
all possible subsets and print all subsets whose sum is 10,
Assume all elements in the array are distinct.
Exa:- input:---{1,2,6,3,4};
Output:-
Hi,
I just modified the powerset problem to print only if the sum is matched as
below.
http://codepad.org/B72idYnp
I think this algo is order of exponential time on number of elements in the
set.
I would be interested to know if there are more efficient algorithms.
Thanks,
Balaji.
On Mon,
there s O (2^(n/2) ) solution with binary searching for sum :)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
Dear All,
Increasing integers can be defined as each of their digits is not greater
than the digit to the right, and integers for which each digit is not lesser
than the digit to the right as decreasing integers. For example 24558 is
increasing, 888410 is decreasing and 5 - is both increasing and
DP
and a SPOJ Problem to :)
http://www.spoj.pl/problems/MONONUM/
On Mon, Jan 24, 2011 at 3:55 PM, monu monu.rath...@gmail.com wrote:
Dear All,
Increasing integers can be defined as each of their digits is not greater
than the digit to the right, and integers for which each digit is
DP and clarify your incorrect question.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For
Its name is meet-in-the-middle technique.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
What is incorrect in the given question, except the constraints not given.
On Mon, Jan 24, 2011 at 4:03 PM, juver++ avpostni...@gmail.com wrote:
DP and clarify your incorrect question.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To
internal stack != extra space
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more
Also has any one solved https://www.spoj.pl/problems/MONONUM/
with only DP. I would like to know the solution, as my solution works for
small nos. and then the ratio reduces to a simple mathematical formula.
On Mon, Jan 24, 2011 at 4:09 PM, Manmeet Singh mans.aus...@gmail.comwrote:
What is
@fight incorrect -
how to calculate the number of the decreasing *n*-digit integers to the
increasing *n*-digit integers
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To
DP[i][sum] - true if sum can be achieved using first i numbers.
then your answer is dp[n][0].
use shiftings (offset) to work with negative numbers
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to
ok, i thought he wanted the both, but he means ratio i guess. So, its the
same problem.
On Mon, Jan 24, 2011 at 4:21 PM, juver++ avpostni...@gmail.com wrote:
@fight incorrect -
how to calculate the number of the decreasing *n*-digit integers to the
increasing *n*-digit integers
--
You
@JUVER++ : One personal question. Is this algo groups paying you something
or you among the admins :) :). As in every problem I find your name and with
a superb solution.
On Mon, Jan 24, 2011 at 4:26 PM, Manmeet Singh mans.aus...@gmail.comwrote:
ok, i thought he wanted the both, but he means
i goes from 1 to n, whats the range of sum in the 2d matrix?
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
*Need: .NET / Web Developer in Western Suburbs of Chicago
*
*Location**:** Chicago*
*** Requirements* *Qualifications*:
*• Full SDLC experience including requirements, design, development,
testing, documentation, etc.
• 7+ years working as a software engineer/ developer/ programmer building
*Need* -* Lotus Notes/Domino/BlackBerry Administrator *
*Location:** Pittsburgh, PA*
*Duration:** 6+ Months*
*Job Description:*
*• Provide 3rd line client support for Lotus Notes to helpdesk (1 users)
*
*• Provide 3rd line client support for Lotus Notes to various clients and
helpdesk
•
*Need:*SQL Server BI
*Location:* *San Diego, CA*
*Duration: *3 months
*Job Description:*
*- Good experience in SQL Server analysis Service 2005 with BI*
*- Able to write complex MDX query*
*- Experience in SSIS*
*- Designing MOLAP *
*
Please ban this guy from group.
On Mon, Jan 24, 2011 at 10:32 PM, Nick smith nick.dwl...@gmail.com wrote:
*Need:*SQL Server BI
*Location:* *San Diego, CA*
*Duration: *3 months
*Job Description:*
*- Good experience in SQL Server analysis Service 2005 with BI*
*-
@fight :) it's only for my pleasure :)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For
hey, but what's the solution to the problem...how to calculate the
ratio ??
On Mon, Jan 24, 2011 at 11:19 PM, juver++ avpostni...@gmail.com wrote:
@fight :) it's only for my pleasure :)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks
n / 9.0 + 1 for n 20 works, before that I apply a simple DP. even i want
to know a gud DP based solution for the problem, with no formula used, as I
have done.
On Mon, Jan 24, 2011 at 11:43 PM, Logic King crazy.logic.k...@gmail.comwrote:
hey, but what's the solution to the problem...how
help me solve the problem...how to approach the problem ??
https://www.spoj.pl/problems/MBINGO/
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from
dp[i][j] - how many numbers of length i and with the last digit j.
Apply the scheme to increasing and decreasing number, then find ratio.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to
Just simulate what the problem asks for.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
*Need:**UI Developer with Dashboard Experience*
*Location:**Irving, Texas*
*Duration:**3-6 months*
*Job Description:*
*-User Interface (UI) development
-Expert Flash**
-Coding in Flash as well
-Expert Graphic Design
-Strong experience in Dashboard *
*Please send your resumes only to
Here is my implementation ;)
#include iostream
#include cstring
using namespace std;
int balls[91]; //maximum balls
int N;
//verify if its impossible to call out every number from 0 to N
bool impossible(){
int i,j;
if(!balls[0])return true; //if ball 0 was removed
*Job Title: NetApp Snap Manager
Location: RTP, NC /KOP-PA
Duration: 4 + months *
*Job Description:*
*Client is urgently looking for SNAP Manager for its NC or PA location.*
*Keywords:** Snap Manager, Snap Mirror, Snap Viewer, SAP, AIX, Netapp etc*
*Job Description: *
- *Tasks we would have
@rgap
i think u have misunderstood the question
u are solving for old version of game
it says solve for new version specified in 2nd paragraph
but not a big problem, can be done with slight modifications
as input is small, just generate all B^2 possibilities and keep track of
absolute differences
Any mentor here who can stop these spams?
-Regards
*Amit Agarwal http:///www.amitagrwal.com*
+91-779-822-8765
On Mon, Jan 24, 2011 at 9:13 PM, Nick smith nick.dwl...@gmail.com wrote:
*Need* -* Lotus Notes/Domino/BlackBerry Administrator *
*Location:** Pittsburgh, PA*
*Duration:** 6+
If the same question is modified as:
Find two numbers whose sum is closest to zero in the given array.
On 24 January 2011 16:08, juver++ avpostni...@gmail.com wrote:
Its name is meet-in-the-middle technique.
--
You received this message because you are subscribed to the Google Groups
http://www.cs.princeton.edu/~wayne/cs423/demos.html
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at
Banned from the groups.
On Mon, Jan 24, 2011 at 11:30 AM, Nick smith nick.dwl...@gmail.com wrote:
*Need:**UI Developer with Dashboard Experience*
*Location:**Irving, Texas*
*Duration:**3-6 months*
*Job Description:*
*-User Interface (UI) development
-Expert Flash**
-Coding in
@Siddharth
If the range is 0 to 9 as specified in the first problem statement, it will
be just finding the two minimum elements.
However if the input range is unknown, it can be solved through an entirely
different approach after sorting and then using two pointers moving either
side from the
It looks like finding all subsets of a set which satisfy a condition
(sum is ZERO).
Using bit approach
i.e.
01101 == 120,150, 316
10100 == -466, 150
int main(int argc, char *argv[])
{
int sum = 0;
int tmp=0;
int i=0;
int a[10]={-466, 120, 150, 421, 316};
int length = 5;
int
You re right, but this code runs slower
#include iostream
#include cstring
#define ABS(x) ((x0)?(-(x)):(x))
using namespace std;
int main(){
int N,B,i,j,k,c,dif;
int R[91];
int balls[91];
while(cinNB,N,B){
memset(balls,0,sizeof(balls));
for(i=0;iB;++i)
Banned.
On Mon, Jan 24, 2011 at 2:06 PM, Upender Gaadi
upender.staff...@gmail.comwrote:
*Please send profiles to upen...@erpanderp.com*
**
*Direct Client Requirement :*
*
Position Title: Network QA Engineer
Duration: 12 Months
Location: San Jose, CA*
*Locals Only*
**
*Very strong
Thanks for sharng :)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more options,
@
Dave
How did you come up with this solution?
Also Y=floor(B)/2+.5 , X=-A*(B-Y) or X=-AB +AY or Y=X/A+B . this is
the equation of a line with slope 1/A and an intercept of B on Y
axis .I don't quite get this.!!Please elaborate .
Meanwhile , this is my approach .
The slope of the line wil be
@Sankalp: I wanted a point far enough outside the region that a line
from any point in the region could not contain any other point in the
region. There are several implications: 1) if the point is to the left
of the region, it can't have an integer y coordinate between 0 and B.
That is where the
43 matches
Mail list logo