₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,325,153 members, 8,420,585 topics. Date: Friday, 05 June 2026 at 04:58 AM

Toggle theme

Collinsanele's Posts

Nairaland ForumCollinsanele's ProfileCollinsanele's Posts

1 2 3 4 5 6 7 (of 7 pages)

ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 5:56pm On Apr 26, 2020
jayphe:

Exercise 5
Write a Python program that accepts a string and a character from the user. The program checks the number of times(frequency) the character appeared in the string. E.g. If the user enters "Michael Faraday" as the string and enters 'a' as the character, the program should display:

There are 4 a in Michael Faraday!


Collinsanele Taofeekdboy kensmoney Daddyshome Zabiboy
def count_char(string, char):
return "There are "+ str(string.lower().count(char)) + " "+ str(char) + " in " + string



print(count_char(string="Michael Faraday", char='a'))
Christianity EtcRe: My Experience With The God Of No Impossibities by Collinsanele: 9:57am On Apr 26, 2020
lincsnuel:
Baba, it was your conscience at work and not because of any God.

You have a good heart, or may be you felt it wasn't worth it. Or maybe you've not seen a good opportunity to steal big money. You won't realize how easily humans drop their principles when given a lucrative option. Every human has a price.
Speak for yourself man.
He has told you his own, don't impose your opinion on him or others.

If you believe in God, fine and good for you, and if you don't, fine and good for you too.
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 9:26pm On Apr 25, 2020
nwele2017:
I want to commend what you are Doing here, it will really go a long way in helping python programmers that look down on this little excersis.
Why Nigeria programmers don't get good jobs is because the over look all this small excersis ,there is a lot of Nigeri professional programmers who cannot write a simple syntax that will evaluate the root of a quadratic equation.
I am afraid you are not correct.
Coding is not about syntax but thinking and problem solving.

If you write a program to solve a quadratic equation and it fails, you simply debug it and try again, that's testing, you must not be correct in one go.

And Nigerians have good coders fyi
ProgrammingRe: For Django Developer by Collinsanele: 1:41pm On Apr 25, 2020
Taofeekdboy:
Yes. I agree with you.
Mostly forms are inheriting from ModelForm unless you are using a form that does nothing with your model or you just want to simplify things, rather than using forms and later incorporate it to your Model. It might be time consuming tho.
The part in Django that I am still struggling with is user registration, login and logout.

I have noticed most things are based on oop (classes) and inheritance.
ProgrammingRe: For Django Developer by Collinsanele: 12:18pm On Apr 25, 2020
Taofeekdboy:
Bro, we are in the same boat, I love writing my views in functions because I will be able to express myself without initiating anything.

All my Django projects was written in function based views, unless I am using DRF, then I write in class based views.
Function based views has been my savior.
Nice!
So it's not only me.
With function based views, I can be in total control and be flexible.

For forms, I prefer using ModelForm if possible.
ProgrammingRe: For Django Developer by Collinsanele: 11:21am On Apr 25, 2020
Taofeekdboy:
I created this thread for Django aspirants, intermediate and experienced Django developers to share knowledge and projects that you have or been working on.

I have worked and been working on a lot of projects such as sport app, loan calculator, and employee management.
The one I just finished is just a social media clone project and it took a bit of my time.

The website is down below:
http://mysocialapp.pythonanywhere.com
If you are interested, you can Check and leave your comments as well.

So let's share ideas and knowledge.....
Talking about Django, I have started using it.
I don't just know why, but I prefer using function based views. What's your preference guys
ProgrammingRe: Which One Is Better: Python Django Or Php? by Collinsanele: 11:16am On Apr 25, 2020
Barney001:
Hi guys,
So I just started learning python ,although I learnt php in the past. But I would like to know which one is better for web development .
I don't know much about php(Laravel) because I am a Python programmer.

I would say learn Django, it has a steep learning curve though but once you get the hang of it, you would keep loving it.

Another Python web framework is Flask, it's a micro framework that's easier to learn.
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 10:28pm On Apr 24, 2020
kensmoney:
import datetime

date_and_time = datetime.datetime.now()
today_date =(str(date_and_time))
today_date_slice = ( today_date[:10] )
formated_date = today_date_slice.replace( "-", "/"
)
year = ( formated_date[:4] )
month_and_date = ( formated_date[5:] )

mydate= month_and_date + "/" + year
print(mydate)

#04/24/2020
You don't need to slice.
year = datetime.datetime.now().year
month = datetime.datetime.now().month
day = datetime.datetime.now().day
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 10:17pm On Apr 24, 2020
Taofeekdboy:
I saw this late, I have been busy with my project and it took a lot of my time.
I will leave it here for who is interested to check..
It is a social media clone I made.
http://mysocialapp.pythonanywhere.com

Looking forward to your comments
You used Django right?
It's really nice
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 8:59pm On Apr 23, 2020
jayphe:
you're making a mistake....
What is the mistake
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 4:23pm On Apr 23, 2020
site ="https://www......"

domain = site.split('//')[1].split("www.")[-1]

print(domain)
ProgrammingRe: Python 3: Exercises And Solutions. by Collinsanele: 10:51am On Apr 23, 2020
website = "www...."
domain = website.split("http://www.")[1].split('/')[0]
print(domain)
HealthRe: Chinese Doctors In Nigeria End 14-Day Isolation Today by Collinsanele: 9:01am On Apr 22, 2020
NaijaRoyalty:
Chinese doctors that couldn't save the lives of their own citizens

rubbish

this government looking for every means possible to steal money
You don't know what you are saying.
China is doing well in the fight of corona virus.
CrimeRe: Update On The Killing Of A Driver, Amobi Igwe By A Civil Defence Officer (Graphi by Collinsanele: 4:28pm On Apr 16, 2020
Judging from the blood stain, we can deduce that the bullet most likely hit the deceased upper chest region. If the so called officer actually aimed at the tyres, it would be impossible for the bullet to hit his upper chest region.
The foolish officer simply shot at sight (from his eye level). The story from the letter was drafted by an slowpoke.
He who lives by the sword dies by the sword.
PoliticsRe: Akure Explosion: I Didn't Know There're Explosives In My Truck, Truck Driver by Collinsanele: 7:06pm On Apr 02, 2020
We are not fools please. If you were even 10 meters to the area of explosion, we would not have even seen your body tissues.

Use your common sense oga driver.
HealthRe: China Finds New Strain Of Coronavirus Which Lasts For 49 Days Emerges by Collinsanele: 3:26pm On Apr 02, 2020
Iyiataata92:
How can you take out almost 2 billion people from world map?
Easier said than done
Have you heard of nuclear energy
PetsRe: Idemili Python Visited My Site, This Year Will Be Great (Photos) by Collinsanele: 8:32am On Mar 22, 2020
I am from Njaba Imo State and we don't kill eke (Python).
NYSCRe: Corpers Pay ‘Thank You’ Visit To Buhari Over N33,000 NYSC Allowance (Photos) by Collinsanele: 6:24pm On Feb 09, 2020
Pay your visit to NLC not the president.
CultureRe: Oba Akintunde Akinyemi Threatens To Release ‘Warriors’ Against Herdsmen by Collinsanele: 8:30pm On Jan 30, 2020
osuofia2:
fake news, Fulanis are our brothers and not enemies, the Igbos are are just trying to cause disunity among the Yorubas and Fulanis. The igbo people are our problems and not Fulanis,
The oba does not speak for the Omoalabis,
Why did you choose to embrace ignorance and folly.
TV/MoviesRe: Meet Jackye, 2019 BBNaija Housemate Who Is A “Software Developer” (Photo) by Collinsanele: 10:50am On Jul 01, 2019
MrAnele:
Software Programmers are not web designers, they don't have any social life..

If you know you know..
Who told you that. You have a very wrong impression about software developers.
PoliticsRe: Buhari's Government Is Driving Nigeria Towards Disaster & Instability — Obasanjo by Collinsanele: 10:48pm On Jun 11, 2019
Oladelepsy001:
The disaster and instability you're projecting shall only be witnessed by only you and not by us.
Let's tell ourselves the truth. Both the economy and this present government is nothing to write home out. The unemployment rate has really increased.
PoliticsRe: Refineries Lose Over 200 Billion Under Buhari- Punch Newspaper by Collinsanele: 5:50pm On Jun 10, 2019
Joromi12:
Lose how. What kind of mushroom reporting is this. Money was not spent on them. So how dem lose
The money lost is the money from the sale of the products the refineries would have produced if they were in operation during those months of being idle (opportunity cost).
CrimeRe: Suicide And Sniper by Collinsanele: 11:25am On May 22, 2019
JKisOK:
The way suicides have made it first choice, Sniper insecticide may just be attracting unhealthy attention from the authorities. Many Nigerians committing suicide have taken to gulping down the substance, with a highly fatal result.

Relatively new in the market, Sniper appears to have been formulated along the line of Otapiapia, which was also a local anti-pest solution. Otapiapia also in the 1980s and 1990s became a favourite suicide tool, especially in the South-East. Sniper seems to have taken over.

Should the government clamp down on Sniper, it may be shutting down a good business, resulting in job losses, investment trapping, with wide implications for those servicing and benefiting down the product's supply chain.

But this raises several questions.

Is there an iron-clad case to call for banning the production and sales of Sniper?

Does Sniper account for the majority of deaths and is Sniper the only way out for people bent on committing harakiri?

Should the manufacturers of Sniper be blamed for the abuse of their highly effective insecticide?

What will happen should Sniper be banned and depressed and desperate people embrace some other solutions?
Banning sniper is only treating the symptoms and not the major root cause, it would be like banning the whole media because that's the major medium for comparison of social status, appearance, relationship, career etc etc.

With an improved economy and standard of living the rate of suicide would for sure subside.
PoliticsRe: Cooking Gas Consumers Will No Longer Own Cylinders – FG by Collinsanele: 9:53am On May 22, 2019
Teacher1776:
Who benefits from this policy? The consumers or the manufacturers of the cylinders?
What are the problems created by the existing practice?
And by the way who are the cylinders makers bid to benefit from this arrangement? We need to know them.
These are very smart questions you asked?
I won't be surprised if the government just wants to give some person or persons monopoly to manufacture cylinders for some selfish reasons.

To be honest, the federal government did not give cogent reasons for this new policy.

Why can't LPG be piped to the various consumers as it is done in many developed countries.

The federal government has just been making inefficient and sometimes nonsensical policies to bring more hardship for Nigerians.
PoliticsRe: Nigerians Compare Buhari And Trump's Thoughts On Education by Collinsanele: 8:54am On May 21, 2019
patogist:
Few weeks ago, News were making head after Nigerian president, Muhammad Buhari review that Education doesn’t guarantee an automatic employment for a job, that you would have to learn some skills afterwards.

Nigerians have taken to twitter platform to review the difference between our own president Buhari and the US president over Donald Trump recent tweet on graduating students.

https://9jainfoupdates.com/nigerians-come-for-president-buhari-after-donald-trump-tweet-on-education/
Our dear president does not have a university degree or any tertiary education degree so he wouldn't know the worth of being a graduate, if he did, he should have known that learning is a continuous process and learning new skills before or after graduation is still part of learning/education.
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 7:44pm On Apr 09, 2019
EvilSec:
Passwords are useless! 2FA will stop you from logging in even if you have the account's password! Maybe if you stopped googling replies and read what he typed slowly you wouldn't be running round in circles rn.
Sorry I won't bother you again
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 7:42pm On Apr 09, 2019
EvilSec:
It's obvious you know nothing, now you're getting demanding and toxic cause I beat down someone who deserved it with underhanded intelligent strategy.
Good riddance to bad rubbish
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 4:03pm On Apr 09, 2019
EvilSec:
Cookie stealing is easier than bypassing 2FA?? Have you heard of EvilGinx and Modlishka? I doubt if you've ever even hacked at all. This conversation is going nowhere, I'm dropping it.
Have I heard of EvilGinx?..
Like EvilGinx just came out yesterday.

Please don't be so cocky, nobody knows it all.
You can leave thread if you so wish.
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 3:56pm On Apr 09, 2019
Cyberleets:
What is going on here lol

With phishing, you get hold of the password which you can ofcos use to login but then again, 2fa blocks everything

With dictionary attack, Facebook will automatically lock the account trmporary after 3 tries so it's useless

With my list of 600+ foreign Facebook account I got through phishing, I still couldn't pass the checkpoint. u have to explain why u are using another device to login by doing some crazy verification and all that!!

Lemme sound it again!!

You can't carry out dictionary on all login page and Facebook has put security in place in their own.

I know as of 2016, Gmail was vulnerable to it, but I don't know if its working now cos Hydra no longer works on it.

Plus dictionary attack only works on foreign account Becos many uses English word.

If u wanna target Nigerian account, your word list needs to contain names of typical traditional names cos most even use thier ancestors surname cheesy....then again, phishing is the still the best

What I want to be seeing is how to bypass the fucking verification...thanks
Facebook has no max amount of login trials, you can verify, and pwned password wordlists are gotten from data breaches so it contains passwords from data breaches even if the passwords contain native names. For example there was a data breach on LinkedIn last year so LinkedIn passwords database was compromised. There have passwords from over 2000 data breaches and LinkedIn is among.
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 2:45pm On Apr 09, 2019
EvilSec:
Yeah! You would be more likely to crack a FB account after ages of failed attempts. grin grin
Oga if you write the code with a low level language like c and you have a system with a very high processor speed, you would be more likely to succeed. Cookie stealing is easier than bypassing 2FA.And I don't do illegal stuff for the records.
WebmastersRe: For Those That Want To Learn Hacking by Collinsanele: 1:55pm On Apr 09, 2019
Try not to be myopic. If you download the password database from haveibeenpwned.com you would be more likely to crack a Facebook account using dictionary attack. Phishing would not work thanks to 2FA. And yes you can buy breached Facebook accounts passwords wordlist, but it is not open source.

1 2 3 4 5 6 7 (of 7 pages)