Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,160,447 members, 7,843,369 topics. Date: Wednesday, 29 May 2024 at 12:22 AM

Osazeej's Posts

Nairaland Forum / Osazeej's Profile / Osazeej's Posts

(1) (of 1 pages)

Forum Games / Re: Who Is The Survivor In The Puzzle? by osazeej: 12:54pm On Sep 02, 2017
I'm proud of you,
Your parents should be proud of you.
You truly can be proud of your accomplishments.
Continue to nurture your skills...and find your purpose in life.
Have a great weekend.


Enouwem:
73 is the answer!

How?

Consider a case when there 2^numbers in circle. Each time the number reduces by half and finally at the last number 1 will remain.
example – 2^2 = 4
round 1 – 2 and 4 will be killed.
round 2 – 3 will be killed. One Remains

So our aim here should be to reach to a figure when 2^n number will come and person who will be holding the sword at that moment will survive.

when there are 100 people – closet 2^number will be 64.
so here our target it to find the person who is holding the sword when 64 people are remaining.

64 people remaining means 36 people killed.
As every alternate person is being killed so double of 36 i.e 72. So 72 person was killed at that moment and the sword was passed to 73 from 71 after killing 72.

so the moment when 64 people were remaining, 73 was holding the sword,
so 73 will survive the killings!!!

.
.
.
.
.

OR,

Use the Circular Left Shift method

There are 100 people.
100 in binary is 1100100.
Circular left shift 1100100.
We get 1001001.
Convert it back to base 10.
73rd is the last man standing.


OR,

MATHAMATICAL WAY THAT EVERY NIGERIAN WILL UNDERSTAND

First 1,3,5,7,9,11,13,15,17;19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99(got sword, passed to 1)

Then 1,5,9,13,17,21,25,29,33,37,41,45,49,53,57,61,65,69,73,77,81,85,89,93,97(sword passed to again)

Then 1,9,17,25,33,41,49,57,65,73,81,89,97(sword passed to 9)

Then 9,25,41,57,73,89(sword passed to 9 again)

Then 9,41,73(sword passed to 9 again)

Then 9,73(73 got sword & killed 9)

Thus the answer is “73"



Oh! And for the programmers or coders.

PYTHON CODE

# find the survivor
n = 100
peeps = range(1, n+1)
idx = 0
while len(peeps) > 1:
peeps.pop((idx + 1) % len(peeps))
# Trivia: because of changing index and len(peeps),
# the code below is not exactly equal to "idx = (idx + 1) % len(peeps)"
idx = 0 if (idx >= len(peeps)-1) else (idx + 1)

print peeps[0]


Output: 73


JAVASCRIPT

// populate the array for 100 people
var team = new Array();
for (var i = 1; i <= 100; i++) {
team[i - 1] = i;
}

var current;
var next;

var j = 0.
while (team.length > 1) { // loop until only 1 exists
current = team[j];
team.push(team[j]); // move current to the end
team.shift(); // remove from existing
next = team[j];
team.shift(); // delete next
document.writeln("Number " + current + " kills number " + next + "<br />"wink;
}
document.writeln("The last one is number " + team[0]);
//alert(team[0]);

1 Like

Travel / Re: General Guide To Australian Permanent Resident Visa Through Skilled Migration. by osazeej: 12:18pm On Aug 06, 2017
Hi Billy,

Don't stress it. You may go ahead to make payment. I had similar experience and British Council recognize the potential for first timers to write only the first name as their given name consistent with the format of the application form. You will have at least two opportunities to correct it namely at the speaking test day and on the written test day. You will be given an admnendment form to fill before your test on day 1. The amendment would have been implemented by the time you show up for test day 2. In the event that the speaking and written tests are on successive days thus making it difficult to implement an amendment submitted at the first test day, you will be given an admnendment form at the end of the test day 2.

Just focus on preparing for the test. All the best!

billy:
Dear,

Please while registering for IELTS with British Council, where I am supposed to input "given names", I only wrote one name instead of two as it appears int'l passport and I have submitted the application.

Can I still go ahead and make payment? So all the names British Council has is just my surname & first name but the name on my passport is Surname, two other names.

Am I safe to make payment? Hope it wont affect me in any ways in the future?

1 Like

Business / Re: Preventing People From Accessing Their Money Via ATM Is An Invitation To Anarchy by osazeej: 10:13am On Dec 25, 2016
I couldn't agree more. I too would like to meet 1wolex85 for he has consistently displayed impeccable emotional intelligence in his responses.
Justiceotunne:


I am deeply awed by your calmness. Many would have flown off the handle with the barrage of insult hauled at you. You also do have a point in your submission. I'd like to meet u

2 Likes 1 Share

Car Talk / Re: Explaining Catalysts And Catalyst Codes by osazeej: 5:47pm On Feb 03, 2015
nissparts:
Sent...
Much appreciated.
Car Talk / Re: Explaining Catalysts And Catalyst Codes by osazeej: 4:44pm On Feb 03, 2015
@nissanpart.. Greetings, could you please send me the description at xcxcccccc

I need the oxygen sensor spacer for 2005 Corolla which gave an 0420 code. I live in Lagos. Pls assist.
Thanks.
Autos / Re: Free VIN Check FOR CARS FROM USA ,CANADA by osazeej: 7:05pm On Jan 30, 2015
[quote author=Export1 post=30276028]


Thank you very much. I truly appreciate this!
Autos / Re: Free VIN Check FOR CARS FROM USA ,CANADA by osazeej: 12:53pm On Jan 30, 2015
Greetings Export1. Kindly assist to check car with VIN: 1NXBR30E15Z526578
Much appreciated.
Autos / Re: Free Vin Checks And Reports by osazeej: 12:01pm On Jan 30, 2015
Good morning sir. Kindly assist to check car with VIN. 1NXBR30E15Z526578
My email
Much appreciated.

(1) (of 1 pages)

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 18
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.