₦airaland Forum

Welcome, Guest: Register • Login • With Google • Trending • Recent • New

Stats: 3,344,764 members, 8,513,586 topics. Date: Thursday, 05 November 2026 at 08:54 AM

Toggle theme

Losprince's Posts

Nairaland Forum › Losprince's Profile › Losprince's Posts

1 2 3 4 5 6 7 8 ... 60 61 62 63 64 65 66 67 68 (of 104 pages)

Programming › Re: Who Wants A Church Content Management System? by losprince(op): 7:31am On Feb 04, 2017
more pictures

Programming › Re: Who Wants A Church Content Management System? by losprince(op): 7:27am On Feb 04, 2017
Here are some pictures of the system

Programming › Who Wants A Church Content Management System? by losprince(op): 1:18pm On Feb 03, 2017
Hi everyone


I was once moved to build a church content management system to sell to churches, after completing it, I decided that I no longer wanted to sell so I am putting it up for free.

I just created a github repository to host it at /xX3quJ you can read the full description there.

I just want to gauge interest as I haven't really finished commiting the codes to github but the full web app is available and be sent on request

PS nairaland keeps messing with the URI so try

https://github.com/calmjohnson/sanctuary
Programming › Re: Urgent Help by losprince(m): 9:25pm On Jan 31, 2017
Open your web browser

Navigate to Google search

Enter how to flash Lenovo Android phone

Click search



Visit results generated by Google until u find one that helps
Programming › What Goals Did You Set For Yourself As A Programmer? by losprince(op): 4:55pm On Jan 26, 2017
NOTE! This is not a new years resolution...

We are talking about what programming goals you set for yourself, if it helps you can also list out how you intend to achieve those goals.

I'll go first.

Sell my first script on code canyon


Actually learn JavaScript grin

Improve my knowledge of PHP, I want to go past writing CRUD web apps to doing cool stuffs like APIs and other cool stuffs

Write an actuall software to help make web design less geeky and more artistry... cool

Build a game...


Those are my long term goals, for short term goals

Finish this web app I'm writing


Tell this certain client to go suck it that I can't build him a school CMS for 20 k

Hack this other client's website which I built for not completing my payment two months after completing the damn job

Stop learning Assembly
Programming › Re: Php Script Installation On Xamp Server by losprince(m): 12:40am On Jan 21, 2017
It can be done remotely
Programming › Re: . by losprince(m): 8:36pm On Dec 17, 2016
0neal:
thanks

but how do they login if the acct is deactivatedhuh
They can't login no more, what you see are posts the made before disembarking
Programming › Re: . by losprince(m): 8:32pm On Dec 17, 2016
you can't do that

the nobody thing is for users who deleted their accounts
Programming › Re: Can You Solve PHP Problems? Let's Find Out.. by losprince(m): 12:40pm On Oct 08, 2016
the function strpos() is case-sentitive, you should use stripos() instead
Programming › How To Build A Snakes And Ladders Game With C++ (no Gui) by losprince(op): 11:30pm On Oct 07, 2016
I was going through my c++ early projects and saw a couple of games I made with codeblocks and decided to pick this one and share how I made it.

If you are not familiar with the game here is how it is played;
the game is played on a board numbered 1 - 100
you roll a die, whatever you get you move your seed forward by that number, on the board snakes and ladders are strategically placed as obstacles and power ups, if you land at the bottom of a ladder you climb up to the top of that ladder, if you land at the head of a snake you frop to the tail of that snake.

you play the game against the computer, I built it this way because I had no friend who would play with me... they all lacked the finer points of no graphic games.




//first we include the includeables
//the game will require randomness for the die rolling

#include <iostream>
#include <cstdlib>
#include <ctime>
#include <string>

using namspace std; // so we can use 'cout << "Hello World"<<endl;' in the stead of 'std::cout << "Hello World"<<endl;'

//first let us declare a few neccessary functions

void board();//initialize function to draw the board

int check_progress();//initialize function to check game progress

int roll_dice();//initialize function to roll dice

//the we declare some variables

int roll; //holds the rolled value for the player
int computer_roll; //holds the rolled value for computer

int input; //variable to hold the users input, any number to roll dice and 0 to quit game, although entering a not a number value ends the game as well...

int progress; //holds the value for the progress

int player = 0;

int computer = 0;

//both player and computer's initial starting point is 0

int squares[99]; // for the 100 squares, computers right counts from 0


int main() //this is where it all goes down in c++, it's like the canvas for da vinci...
{
srand( time(NULL) ); //we need random numbers remeber?

string alert = ""; //to alert you for your triumphs and misfortunes
string computer_alert = ""; // to alert you for computer's triumphs and misfortunes

cout << "Welcome to snakes and ladders, enter any number to roll dice, press 0 to quit\n\n";
cout << "SNAKES\tLADDERS\n99-5\t4-36\n93-25\t8-28\n77-9\t20-41\n52-6\t35-67\n30-2\t45-66\n\n";

for ( int i = 1; i <= 100; i++) // this loop just makes it possible for us to give our squares values
{
squares[i] = i
}

do // every game is in some sort of loop
{
cout << "enter: ";
cin >> input;

roll = roll_dice();//player rolls dice

if( (roll + player) > 100)
{
player = player; //player has rolled a number that exceeds the end point player remains where they are
}
else
{
squares[player] = player;//overwrite the current position
player = player + roll;//move player to a new position
}

computer_roll = roll_dice();//computer rolls dice

if( (computer_roll + computer) > 100)
{
computer = computer; //computer has rolled a number that exceeds the end point, computer remains where it is
}
else
{
squares[computer] = computer;//overwrite the current position
computer = computer + computer_roll;//move computer to a new position
}

switch(player) // it is snakes and ladders, numbers represent the snakes and ladders
{
case 99:
player = 5;
alert = "OOPS... You ran into a SNAKE!";
break;

case 93:
player = 25;
alert = "OOPS... You ran into a SNAKE!";
break;

case 77:
player = 9;
alert = "OOPS... You ran into a SNAKE!";
break;

case 52:
player = 6;
alert = "OOPS... You ran into a SNAKE!";
break;

case 30:
player = 2;
alert = "OOPS... You ran into a SNAKE!";
break;

case 45:
player = 66;
alert = "YAY! you climbed a ladder!!!";
break;

case 35:
player = 67;
alert = "YAY! you climbed a ladder!!!";
break;

case 20:
player = 41;
alert = "YAY! you climbed a ladder!!!";
break;

case 8:
player = 28;
alert = "YAY! you climbed a ladder!!!";
break;

case 4:
player = 36;
alert = "YAY! you climbed a ladder!!!";
break;

default:
alert = "";

}

switch(computer)
{
case 99:
computer = 5;
computer_alert = "OOPS... Computer ran into a SNAKE!";
break;

case 93:
computer = 25;
computer_alert = "OOPS... Computer ran into a SNAKE!";
break;

case 77:
computer = 9;
computer_alert = "OOPS... Computer ran into a SNAKE!";
break;

case 52:
computer = 6;
computer_alert = "OOPS... Computer ran into a SNAKE!";
break;

case 30:
computer = 2;
computer_alert = "OOPS... Computer ran into a SNAKE!";
break;

case 45:
computer = 66;
computer_alert = "HAHA! computer climbed a ladder!!!";
break;

case 35:
computer = 67;
computer_alert = "HAHA! computer climbed a ladder!!!";
break;

case 20:
computer = 41;
computer_alert = "HAHA! computer climbed a ladder!!!";
break;

case 8:
computer = 28;
computer_alert = "HAHA! computer climbed a ladder!!!";
break;

case 4:
computer = 36;
computer_alert = "HAHA! computer climbed a ladder!!!";
break;

default:
computer_alert = "";
}

squares[player] = 200; //player's position shall be represented by the integer 200
squares[computer] = 300; //computer's position shall be represented by the inteer 300

if ( input != 0)
{
cout<<"You rolled "<<roll<<" Computer rolled "<<computer_roll<<endl;
cout<<"Your Position: "<<player<<" Computer's Position: "<<computer<<endl;
cout <<alert<<endl;
cout <<computer_alert<<endl;

board();
cout << "SNAKES\tLADDERS\n99-5\t4-36\n93-25\t8-28\n77-9\t20-41\n52-6\t35-67\n30-2\t45-66\n\n"; //so the player knows which is a snake and that which is ladder
}

progress = check_progress();

}
while ( progress == 0 && input != 0 );

if ( squares[100] == 200)
{
cout << "||You Win!||"<<endl;
}
else if ( squares[100] == 300)
{
cout << "||Game Over Computer Wins!"<<endl;
}
else
{
cout << "You Quit!";
}

cin.get();
cin.ignore();
}

void board()//define the board drawing mechanism!
{
cout << "----------------------------------------------------------------------------"<<endl<<endl;
cout << squares[100]<<"\t"<<squares[99]<<"\t"<<squares[98]<<"\t"<<squares[97]<<"\t"<<squares[96]<<"\t"
<<squares[95]<<"\t"<<squares[94]<<"\t"<<squares[93]<<"\t"<<squares[92]<<"\t"<<squares[91]<<endl<<endl;

cout << squares[81]<<"\t"<<squares[82]<<"\t"<<squares[83]<<"\t"<<squares[84]<<"\t"<<squares[85]<<"\t"
<<squares[86]<<"\t"<<squares[87]<<"\t"<<squares[88]<<"\t"<<squares[89]<<"\t"<<squares[90]<<endl<<endl;

cout << squares[80]<<"\t"<<squares[79]<<"\t"<<squares[78]<<"\t"<<squares[77]<<"\t"<<squares[76]<<"\t"
<<squares[75]<<"\t"<<squares[74]<<"\t"<<squares[73]<<"\t"<<squares[72]<<"\t"<<squares[71]<<endl<<endl;

cout << squares[61]<<"\t"<<squares[62]<<"\t"<<squares[63]<<"\t"<<squares[64]<<"\t"<<squares[65]<<"\t"
<<squares[66]<<"\t"<<squares[67]<<"\t"<<squares[68]<<"\t"<<squares[69]<<"\t"<<squares[70]<<endl<<endl;

cout << squares[60]<<"\t"<<squares[59]<<"\t"<<squares[58]<<"\t"<<squares[57]<<"\t"<<squares[56]<<"\t"
<<squares[55]<<"\t"<<squares[54]<<"\t"<<squares[53]<<"\t"<<squares[52]<<"\t"<<squares[51]<<endl<<endl;

cout << squares[41]<<"\t"<<squares[42]<<"\t"<<squares[43]<<"\t"<<squares[44]<<"\t"<<squares[45]<<"\t"
<<squares[46]<<"\t"<<squares[47]<<"\t"<<squares[48]<<"\t"<<squares[49]<<"\t"<<squares[50]<<endl<<endl;

cout << squares[40]<<"\t"<<squares[39]<<"\t"<<squares[38]<<"\t"<<squares[37]<<"\t"<<squares[36]<<"\t"
<<squares[35]<<"\t"<<squares[34]<<"\t"<<squares[33]<<"\t"<<squares[32]<<"\t"<<squares[31]<<endl<<endl;

cout << squares[21]<<"\t"<<squares[22]<<"\t"<<squares[23]<<"\t"<<squares[24]<<"\t"<<squares[25]<<"\t"
<<squares[26]<<"\t"<<squares[27]<<"\t"<<squares[28]<<"\t"<<squares[29]<<"\t"<<squares[30]<<endl<<endl;

cout << squares[20]<<"\t"<<squares[19]<<"\t"<<squares[18]<<"\t"<<squares[17]<<"\t"<<squares[16]<<"\t"
<<squares[15]<<"\t"<<squares[14]<<"\t"<<squares[13]<<"\t"<<squares[12]<<"\t"<<squares[11]<<endl<<endl;

cout << squares[1]<<"\t"<<squares[2]<<"\t"<<squares[3]<<"\t"<<squares[4]<<"\t"<<squares[5]<<"\t"
<<squares[6]<<"\t"<<squares[7]<<"\t"<<squares[8]<<"\t"<<squares[9]<<"\t"<<squares[10]<<endl<<endl;
cout << "----------------------------------------------------------------------------"<<endl;
}

int roll_dice()//define the dice rolling mechanism
{
return rand() % (7-1) + 1;//can only roll 1 - 6
}

int check_progress()//define the progress checking mechanism
{
if ( squares[100] == 200 || squares[100] == 300)
{
return 1;//game has ended... win! someone has
}
else
{
return 0;//game is still on, win no one has...
}
}




hope you enjoyed it as much as I did...
I will post more of my little projects for newbies like me to learn an draw inspiration from cool
Literature › Re: The Journal Of A Nymphomaniac by losprince(m): 10:53pm On Oct 07, 2016
I always knew you would write someday...

I am enjoying this grin the story not the seun and obinna thingy angry I liked the twist to the last update good work twaci!
1 Like
Programming › Re: The most popular programmer on Nairaland 2016 Edition by losprince(m): 10:44pm On Sep 20, 2016
I nominate losprince www.nairaland.com/losprince
Programming › Re: Tytit users keep growing since it launched on 7th September by losprince(m): 2:55pm On Sep 07, 2016
I visted and saw that you have only two tytles, one points back to nairaland and the other was posted a month, people will keep visiting your site if they see an activity going on there and that should start with you. overall nice site, just that new users sees nothing on their homepage...
Crime › Re: Man Rapes 2-Year-Old Girl In Lagos by losprince(m): 10:08am On Sep 03, 2016
this moderator is a scum bag can't they just go with "man rapes 2 year old girl?" instead they modify post title to "man tears private part of two year old girl"

just to get more click or what?
Programming › Re: Mysql: I Find This Silly...pls Help Me Out by losprince(m): 11:50pm On Aug 29, 2016
you still need to choose the database you wish to connect to

try mysqli_select_db(“database_name“);
Programming › Re: There Are Only Three Black People In The Silicon Valley TV Show. by losprince(m): 7:31pm On Aug 19, 2016
how many white people do you see in nigerian home videos?
Fashion › Re: Mr Nairaland 2016 - Grand Finale by losprince(m): 3:17pm On Aug 06, 2016
I vote for iamkingzlee Cc: NLjega
Programming › Re: Need Help On PHP by losprince(m): 9:39pm On Aug 03, 2016
you use cookies and sessions to track users, but they expire after a certain amount of time and some browsers don't support cookies or the user may not enable cookies... in this case you use a database
Programming › Re: In Need Of A Web Designer And Programmer by losprince(m): 12:02am On Jul 22, 2016
Good in All programming languages?

Please can you wait a century for me to try and get to that point? huh
Programming › Re: Unbelievable! This App Is Free On Play Store, Every Nigerian must have It! by losprince(m): 5:53pm On Jul 21, 2016
Really LOL
Programming › Re: Php Coders Help by losprince(m): 9:41pm On Jul 17, 2016
Why nt ask the database? ask nicely
Programming › Re: Why Is My Facebook Not Loading? by losprince(m): 11:35am On Jul 13, 2016
Have you tried using a web browser?
smiley
Programming › Re: Why PHP Should Not Be Your Primary Language by losprince(m): 11:41pm On Jul 11, 2016
My bragging right is php7
Politics › Re: Wike Donates 20 Patrol Vans, Bulletproof Vests And Helmets To Police by losprince(m): 8:26am On Jul 08, 2016
Most Nigerian are just plain gullible,

How can a governor who has pledged to serve the state be donating? It's his duty morons!!!
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 5:27pm On Jul 07, 2016
Nihilist:
You might be right.

But be that as it may, it would appear that the night king had hitherto been unable to cross that wall, until the show cast branded stark as a plot device that could potentially serve as a vehicle for the night king's machinations on the south.

I mean if all it took to cross the magical barrier of the wall was a branding, then craster could have served the purpose. He's not far from the wall and already has a working relationship with the nights watch. Or any one of the nights watch company could have been captured and branded during their occasional forays beyond the wall.

That's why i think that the branded stark was and is especially significant. I don't think the night king can piggy back on just anybody. Which again leaves me to think that branded stark can just avert the whole showdown by killing himself or letting himself get killed. At the very least, he can delay the invasion until another raven is born and ventures beyond the wall to get himself branded as well
.
@bolded
The starks are selfless people, maybe the branded stark would just off himself and save the world. Eliminating the need for Arzhor Ahia

but maybe the brand was just for the cave, I mean the three eye raven knew that the mark on branded stark would let the night king into the cave, he could have warned them of the same consequence if they were applicable on the wall but maybe he forgot or just decided to keep that information to himself, Let's hope branded stark doesn't have a hand in letting the night king cross over to the realm of men(no pun intended).

He is caused so much trouble already.
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 3:32pm On Jul 07, 2016
Nihilist:
I really don't understand why there has to be a showdown with the white walkers and their army of the undead.

The whitewalkers cannot cross the wall due to some magical protection. They could potentially cross the wall via branded stark.

But branded stark knows that the undead can't cross the wall. He also knows that the dead can piggy back on him to pass magical security.

So why doesn't he just stay behind the wall and die? if he does that, that's pretty much the whole white walker threat eliminated isnt it?
Every magic has a loop hole, even if "branded" stark does stay behind the wall, It has been said that the night king will find a way to cross the wall someday and that brandon need to be prepared for that. This isn't one of those obvious shows mate, I don't think the night king crossing the wall has anything to do with brans mark.
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 9:52pm On Jul 01, 2016
Nihilist:
I may have to be more discriminating when deciding to who to respond to in future

I will try and answer your post, not because I believe it is of any particular value or worth replying, but just to show how events as they happened are considered irrelevant, when the defence of a beloved character is of utmost concern. Seems like even the facts are not allowed to get in the way of your narrative

For instance.


This is a bold faced lie.

Lord Glover on why he refused to answer Jon -

"Yes, my family served House Stark for centuries. We wept when we heard of your father's death. When my brother was Lord of this castle he answered Robb's call and hailed him King in the North! And where was "King" Robb when the Ironborn attacked this castle? When they threw my wife and children in prison and brutalized and killed our subjects? Taking up with a foreign wh0re... getting himself and those who followed him killed."

You can see that Glover is clearly questioning Stark Leadership here....No mention of the word 'Bastard'
Stark leadership not jons, and he had no right to question stark leadership because it was his bloody castle and everyone was off to war.
The young wolf didn't get everyone killed, he took them to a wedding... It was the boltons, the freys that killed them all..

Lord Manderly on why he refused to answer Jon -

""Lady Mormont speaks harshly... and truly. My son died for Robb Stark, the Young Wolf. I didn't think we'd find another king in my lifetime. I didn't commit my men to your cause because I didn't want more Manderlys dying for nothing."

Again the questions of leadership is raised, framed against a concern that Jon would have the Manderlys die for nothing'
Jons leadership wasn't questioned here, the lord was just skeptical, Jon didn't have the army and to him it didn't seem like jon had a chance of winning

Both Lords are very particular in pointing out that the safety of their men was of utmost priority, and neither one of them felt that Jon could guarantee their continued safety.
Every lord would take their men's safety as utmost priority, they didn't feel jon couldn't protect their men, They feared he didn't have the men to win.

Another bold faced lie. Davos never sold Jon to Lyanna as a great leader. Instead he appealed to her instinct for self-preservation.

His speech below

"Jeor Mormont and Jon Snow both understood that the real war isn't between a few squabbling houses. It's between the living and the dead. And make no mistake my lady, the dead are coming."
As long as the Boltons hold Winterfell, the North is divided. And a divided North won't stand a chance against the Night King. You want to protect your people my lady, I understand. But there's no hiding from this. We have to fight. And we need to do it together"
He outrightly sold jon as a great leader, Only a great leader could see beyond the fights against a few squabbling houses and want to unite everyone to fight a greater enemy, that's why he led the wildlings past the wall in the first place

I agree...which is why I did not focus on that in isolation. Like I said, he saved some of them from the whitewalkers and then offered them sanctuary at Castle Black doing away with a tradition that has held several centuries, and at the expense of his own life...yet these guys are still reluctant to fight for him at Winterfell. He has made enormous sacrifices to keep the wildlings alive, and yet was still unable to muster their loyalty without help- HOW COME?
You can't just walk up to the free folk and ask them to follow you to a fight that doesn't really concern them, you saved their lives on the condition that they would fight with you against the white walkers and they agreed, anybody would be relunctant.... also remember when jon was dead at the wall it was the free folk who unrelunctantly rushed there to avenge his death. Besides people would only follow you when you give them a strong reason to not because you did something for them.

This is exactly the point. The Lord Commander of the night's watch perfomed an noble act that was morally right. Yet his subordinates disagreed so strongly with his decision that they actually chose to MURDER HIM. If that is not the biggest exhibit of a lack of faith in his leadership, then I don't know what is.
Those men bore him no love, Ser alliser had already twisted their minds.

I'm done with this debate. I cannot continue to repeat myself and deal with the same non-coherent arguments time and again.
GOOD cool
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 9:49pm On Jun 29, 2016
Nihilist:
My point is actually not based on hindsight at all.

The Lords of the North had the foresight to realise that Jon Snow was going to lose to the Boltons, and decide to preserve the lives of their men by abstaining.

Sansa had the foresight to know that Jon would lose, and deliberately refused to enlist her forces under his leadership.

The only person to keep faith with him was a child who naturally isn't mature enough to fully understand the consequences of enlisting her men in a war they couldn't win.


This bit is particularly crucial because they all knew that this guy didn't have the men, the parentage or the acumen to take on the warden of thr north(by royal decree no less)

So what happened?

They fought, Jon lost, and was rescued by forces who he had neither summoned, nor had under control.

Does it sound logical that when he was shouting 'we fought, we won etc', that not a single person there would point out that he actually had to be rescued from his folly?

So Baelish just sat down there and let Jon share the credit, especially when littlefinger didn't even come to the battle for Jon?

my point has been simple, Jon has been making some pretty bad decisions, and his only backer up until ep 10 was a child....so why has no one called them out on this? cheesy
Battles Have Been Won Against Greater Odds!

Nobody knew jon would let his emotions get the best of him, If they stuck to their plan there was hope of victory for them.
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 6:37pm On Jun 27, 2016
Boring:
hello bae cool
I don't know why she is doubting the fact that she is a great beauty

TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 2:38pm On Jun 27, 2016
For the first time since I found this thread smiley I'm actually anticipating an argument grin


So dear arguers... Bring it on, make it firery, make it bloody,
TV/Movies › Re: Game Of Thrones Discussion (Beware Of Spoilers) by losprince(m): 9:01am On Jun 27, 2016
They should just wed lady lyanna to jon snow smiley

She deserves to be the queen in the north!!!

And arya? Thanks for killing that useless old man wink but she should have said "the starks send their regards or the north remembers..."

Now the queen of queens is headed to westross grin Cersie is just warming the iron throne with her cold booty for the draagon queen.


BLOOD AND FIRE!!!

JON TYGAREAN!!!

King In The North!!!

1 2 3 4 5 6 7 8 ... 60 61 62 63 64 65 66 67 68 (of 104 pages)