₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,325,090 members, 8,420,264 topics. Date: Thursday, 04 June 2026 at 03:06 PM

Toggle theme

Shepherdd's Posts

Nairaland ForumShepherdd's ProfileShepherdd's Posts

1 2 3 4 (of 4 pages)

PoliticsRe: Jonathan Remembers Yar'adua 10 Years After. Says He Was 'Selfless' & 'Modest' by Shepherdd(m): 10:35am On May 05, 2020
RIP Good Man. A good example of what a leader should be.
ProgrammingRe: What Is A Framework? by Shepherdd(m): 10:45pm On May 02, 2020
stanliwise:
MVC is a design pattern o. Don’t get it twisted, how can someone say MVC is not a design pattern but an architectural patternhuh
Is architectural pattern not a sub category of of design pattern? So as behavioral too.

For the banking you mention I wasn’t referring to some funny system. If so then we have many.

MVC is for anything that have graphics. If your application has a user interface then MVC or its derivative is a must for you especially when it gets large.

For other system like mails and servers they could use other Kind of design pattern rather than MVC. This is because the don’t contain graphics or any UI interface.
Ok wait.

Is architectural pattern not a sub category of of design pattern? So as behavioral too.
Design Patterns are more localized, they don't affect how you structure your overall code, they affect a specific section of your code they deal with common design problems following object oriented design principles. Design patterns are language or technology agnostic, they don;t care about the domain.

Architectural Patterns have an heavy impact on the code base, most often impacting the whole application either horizontally (ie. how to structure the code inside a layer) or vertically (ie. how a request is processed from the outer layers into the inner layers and back).(stackoverflow)

If MVC is a design pattern can you compare it with other design patterns ? does it fit with them.

stanliwise:
MVC Is both to the best of my knowledge. Although I think it is more of design pattern for GUI or better still an architecture for graphics.
This is correct. MVC was originally created for smalltalk and graphics alone then it was later adopted as an architecture for the web.
ProgrammingRe: What Is A Framework? by Shepherdd(m): 9:32pm On May 02, 2020
ubsky:
MVC is neither a design pattern or a technology. It's a software architecture pattern,the difference between a design pattern and a software architecture pattern is that design patterns tend to be simpler and apply to specific components of an application, while architecture patterns are broader and apply to the application as a whole.
Well said, No way MVC is a design pattern. MVC doesn't care whether you are using singleton, creational, composite e.t.c

stanliwise:
mention the other design pattern!

Almost all other large pattern e.g MVVM and the likes are MVC derivatives . MVC remains the dominant pattern for complete software dev. MVC is a large pattern that contains and houses almost all other kind of pattern. So it will always be the dominant pattern you will see
How about the Client-server pattern used in banking, or email systems or Broker pattern which is dominant for any reasonable Big data project.
ProgrammingRe: I Find It Hard Learning Javascript...i Need Help by Shepherdd(m): 5:07pm On May 02, 2020
geedot:
Data structures and algorithms knowledge can't be over emphasised, I wish I knew earlier before I started learning programming. Now we have to do it the hard way by learning Data structure along side programming which is not easy at all.
I guess that's the norm(learning DS&A later) unless you studied computer science.
Data structures and algorithm are language agnostic and I also think they should be learned before even trying to print Hello World on the console.
ProgrammingRe: I Find It Hard Learning Javascript...i Need Help by Shepherdd(m): 10:18am On May 01, 2020
AyomideToks:
Thanks I really Appreciate this
What projects CAN I begin to work on as a beginner to make the learning process fun??
Since you said you have a background in HTML and CSS, why not build a clock with html / css and update the time with JS. You will need to use tools like setInterval.

You can try to build the snake game, a to-do list, a note taking app, you could go further by learning graphics rendering with JS(three.js, pixi.js) and build stuff like tic-tac-toe, and WHOT game.
ProgrammingRe: I Find It Hard Learning Javascript...i Need Help by Shepherdd(m):
Please don't start with that book. For any programming language I want to learn I always download two or more kinds of textbook, the one targeted for purely beginners(head first series or dummies series) and a more advanced version.

For a more subtle introduction to JavaScript please download JavaScript for dummies. It's really easy to grab and you get to implement some cool programmes along the way.

Once you are done then you can move to more complex books like eloquent, you don't know JS and the likes.
ProgrammingRe: Python 3: Exercises And Solutions. by Shepherdd(m): 10:08am On Apr 28, 2020
jayphe:

Exercise 6
Write a Python program that accepts an integer number and checks if it is an even number or an odd number. Pls don't use the % (modulus) operator. Let's see some genuius.
def check_type(val):
_type = 'even' if val & 1 == 0 else 'odd'
return _type
TravelRe: A-29 Super Tucano Aircraft For Nigeria Marks First Flight In Florida by Shepherdd(m): 8:46pm On Apr 20, 2020
If they are fighting with fulani herdsmen i think these toys will be effective but if they are for fights against terrorism, any surface-to-air missile will shoot these down. They should get at least any lockheed martin craft (f-22, 35, 21, 16)
Jokes EtcRe: Meet The Dancing Pallbearers Who Have Become An Online Sensation by Shepherdd(m): 9:01pm On Apr 19, 2020
IME1:
sad it's not dignifying to dance, make comedy or fun of burials, caskets or corpses

Even in death there is dignity of the person.

I don't support the sumersaulting intrigues of some pall bearers, but I blame the family members who can't caution them.
If you want to laugh, laugh at the chat below
Actually those families in the video requested it (I saw an interview of one the family member i think on bbc news africa)., The band in particular is known for their stunt and all.
ProgrammingRe: Fizz Buzz by Shepherdd(m): 6:28pm On Apr 11, 2020
nosagold:
Like this...
Yes Exactly.
ProgrammingRe: Fizz Buzz by Shepherdd(m): 3:54pm On Apr 10, 2020
Lawren76:
Hi guyz keep hearing this fizz buzz of a thing test
people keep saying it hard pls what the hell is the
FIZZ BUZZ TEST
FizzBuzz is a simple interview question designed to weed out "programmers" who can't actually program.

The test:
Print every number between 1 and 100, However for numbers that are multiples of 3 print "Fizz" and for numbers that are multiples of five print "Buzz." For numbers that are multiples of both 3 and 5 print "FizzBuzz".
ProgrammingRe: Coding For D Gurus:#challange by Shepherdd(m): 3:35pm On Apr 10, 2020
Lawren76:
First of all am very happy u did it,secondly if u check it the program knows which come first i.e row then column

So urs don't have type checking it works that all i do first then i make it efficent next
My bad. I made the comment based on the example and not on the actual code.....
ProgrammingRe: Coding For D Gurus:#challange by Shepherdd(m): 10:08am On Apr 10, 2020
Lawren76:
Firstly am not a guru bt if u r then am sure this challange shld be a breeze for you the challange is to write a program to manipulate a matrix it shld be able to do the following to a matrix:
1.Transpose a matrix:
Input: 1 2 3
4 5 6
7 8 9

Output:1 4 7
2 5 8
3 6 9
2. Find the dot product of a matrix:
Input: 1 2 3
4 5 6 *2
7 8 9

Output: 2 4 6
8 10 12
14 16 18
3. Create a Matrix:
Input:4*3
Output: 1 2 3 4
5 6 7 8
9 10 11 12

##################################
This challenge is for those who just love a bit of a challange nd the gurus who i hav been seeing dishing out some nice pice of algo. Not for money or any cash prize just for the joy of CODE
Enjoy
##################################
P.s after 3 days i will post the answer written in python bt it is still an algorithm so just follow it to understand python is kinda like pseude - code
###################################
def transpose(array):
v = [list(map(lambda x: x[ix], array)) for ix in range(len(array[0]))]
return v

def dot(array, constant):
d = [[x * constant for x in val] for val in array]
return d

def create(size_tuple, placeholder):
# size_tuple (row * column) i.e create((4,3), 0)
v = [[placeholder for i in range(size_tuple[1])] for i in range(size_tuple[0])]
return v


Note that your matrix creation contains an error. Matrix size is (row x column) not (column x row). And no assertion and type checking is done n my code.
ProgrammingRe: Arduino Programming Boards, Shields, And Sensors Purchases by Shepherdd(m): 10:45am On Apr 05, 2020
arduino:
We Thank all our customers especially those of Nairaland community from Northern to Southern Nigeria and Eastern to Western Nigeria and even those that ordered from Sambisa Forest....... We are grateful
Hello interested in getting these boards very soon. Your konga link is down how can i see you catalog of boards.
ProgrammingRe: Please Help With Javascript by Shepherdd(m): 9:31am On Apr 05, 2020
manando1:
my page is made with HTML CSS and JavaScript.
ok. You can get the current dj count using a Javascript query selector then you increase the count and you set the count back.

It will look something like

<form>
<input type="text" id="dj_likes" value="0"/>
<input type="button" onclick="increaseLike()" value="number of likes" />
</form>

const increaseLike = ( ) => {
var like_count= parseInt(document.getElementById('dj_likes').value, 10);
like_count= isNaN(like_count) ? 0 : value;
like_count++;
document.getElementById('dj_likes').value = like_count;
}


Note the likes will be zeroed on browser refresh or close. To fix this you could save the counts to local storage or implement a backend (I would recommend Express with Javascript as you are familiar with Javascript already).
ProgrammingRe: Please Help With Javascript by Shepherdd(m): 10:58pm On Apr 04, 2020
manando1:
Hy, i'm making a site were i have a page that have a number of dj's and i put a button for everyone to vote. However, i don't know how to count the votes per dj and display votes
Please help
Are you using any back end to persist your data? Or your page is built with only HTML CSS and JavaScript.
HealthRe: FACT-CHECK: Is Coronavirus Caused By 5G Technology? by Shepherdd(m): 9:59pm On Apr 04, 2020
Dumb Fuccks. If the radiation of 5G is so bad now compare it with direct solar radiation (solar radiation is ionized and radio waves aren't) that astronauts are exposed to on the international space station. Scot Kelly spent a fucking year in the ISS and my guy is still very healthy.
ProgrammingRe: Is My Files And Database Safe With Hosting Company? by Shepherdd(m):
MrBible:
Obfuscation and compiled files are not the same, you need to learn about them. Obfuscation locks the application with a key after compliling it to make it very difficult for someone else to unlock and use your application.

When an application is compiled it just makes the application to load quicker as the compilation has aready been done.
Glad you said very difficult which means not impossible. Everything is possible what matters is the motivation behind it.

There are tools like JSNice and JSBeautify that de-obfuscate JS files, I have used them personally to de-obfuscate some critical part of code I obfuscated (I lost the original code). And there are many more de-obfuscator for other languages. I have even seen an obfuscated Java bytecode .class file converted back to a .java source file.

Although their output will differ from the original in stuffs like variable names, but I assure you the code is 100% functionally correct and to a skilled serious person, reverse engineering this is doable.
ProgrammingRe: Is My Files And Database Safe With Hosting Company? by Shepherdd(m): 6:43pm On Mar 30, 2020
.
ProgrammingRe: Is My Files And Database Safe With Hosting Company? by Shepherdd(m): 4:37pm On Mar 29, 2020
No need to be worried about your db unless you are using SQLite as all main db requires password and you can even go a step further by carefully sharing rights for the database users.

About the files, that will be tricky or impossible cause uploading compiled files can even be decompiled back to the normal plaintext so to have a rest of mind just steer clear from these hosts.

Google cloud offers a full year free hosting, Azure does too, am not sure about AWS. Depending on the language used for the website other cheap alternatives might exist like PythonAnywhere for Django, HostGator for NodeJs e.t.c
ProgrammingRe: Chronicle Of A Data Scientist/analyst by Shepherdd(m): 4:52pm On Mar 26, 2020
noob03saibot:
I agree with you wholeheartedly with this. What I intend doing is to starve myself of pycharm for a week or two and force myself on jupyter. Pycharm is like driving with an automatic whereas jupyter is like driving with a manual in terms of punching out the codes. If after a week or two and I am not still feeling it, then would learn how to and start importing and working with libraries on pycharm. But for now will endure.
Nice starving yourself from PyCharm it will really help you. Remember when I had to abstain from IntelliJ and I was using Notepad++ for my coding although it was a pain in the beginning but it cemented the little basics.

Jupyter also performs little code completion by pressing the tab key like when you want to access a method from an object or reference a declared variable and it is less Ram hungry compared to PyCharm.
ProgrammingRe: Criticize My Algorithm by Shepherdd(m): 4:14pm On Mar 26, 2020
Also try and work on your variable naming and comments keeping in mind that you won't be the only one working with your code and even you after some years might find it hard to figure what a line does when you don't have good variable names and concise comments.
ProgrammingRe: Criticize My Algorithm by Shepherdd(m):
By mere going through the code like that I could observe that your code will run in O(N²) quadratic time which simply translates that as your input increases the time the algorithm takes doubles. The bubble sort is algorithm is a good example of this.

Your search method I think is doing a binary search but you fail to account for the fact that binary search only works on a sorted array. Try and add a line inside the search method to sort the array first.

If you feel comfortable with Python you could replace your sort method with a merge sort implementation which is very acceptable as it has a linear time O(n) worst case scenario.

There is a fairly correct saying that for loops are evil. Try and replace for loops with functional programming methods like filter, reduce e.t.c with Python lambda.

But all in all bravo to you for even trying to code this as many programmers only care about data types and algorithm a week to an interview.
ProgrammingRe: Criticize My Algorithm by Shepherdd(m): 3:31pm On Mar 26, 2020
Can you upload this as a GitHub gist and post a link. It's kinda hard to read because of Python's indentation.
HealthRe: COVID-19: FG Deploys Nigerian Researchers To Search For Cure by Shepherdd(m): 3:26pm On Mar 26, 2020
These clowns won't come up with shitt. They claim they looking for vaccine and yet we don't have any electron microscope in the country to take a good look at this novel virus. We are just wasting our time in this country.
HealthRe: Edo Records First Coronavirus Case: 35 Cases Now Confirmed In Nigeria by Shepherdd(m): 1:21pm On Mar 23, 2020
alsudan:
In one week, Covik One Nine Birus will sweep through Naija.
Really grin grin grin una well done o.
RomanceRe: How Did You Find Out Your Partner Was Cheating On You? by Shepherdd(m): 7:49pm On Mar 22, 2020
wizzyrich:
From the very first day I noticed she does not have a single SMS on her phone. Even the one from Mtn, Airtel, glo and Etisalat, she deletes them.
chai. Awon Edward Snowden Mrs grin grin grin
ProgrammingRe: Chronicle Of A Data Scientist/analyst by Shepherdd(m): 9:54pm On Mar 17, 2020
Ejiod:
1st given their data to work on from home.
2nd was given their data plus theory which was executed in their office
3rd was given their data which I also did from home.

Just understand the data being thrown at you is to check whether you are capable or not and to know how you think about data. Questions on the data are always direct
First I will like to commend and appreciate what you are doing here sir. Only if more veterans can be like you sir.

I also have a similar story to yours during my uni days studying anatomy and once I realized no job for anatomist in Nigeria I started learning JS, then onto Java then Python. With Python and Django I started building stuffs then I added React but at the end of the day I knew I needed more, and during my pre NYSC period I started learning pandas, sklearn, bokeh, pytorch and per your recommendation am diving into visualization with tableau and power bi.

Currently i think I have mastered these to a good extent but I still feel like something is missing. Maybe it's the fact that I haven't really done an end-to-end analysis project due to the fact that I can't get my hands on real world data and requirements.

So my question is what are some recommended projects to get my hands dirty with. And also sir I sent you a mail request here on NL.

Thanks.
Foreign AffairsRe: Trump Calls COVID’19 A “Chinese Virus” by Shepherdd(m): 2:11pm On Mar 17, 2020
I can't seem to fathom while some people still get offended by Trump when it's not a secret the guy is deluded and suffers from a somewhat mini version of schizophrenia.
HealthRe: We Are Not Stopping Chinese, Italians, Others From Visiting Nigeria — FG by Shepherdd(m): 2:03pm On Mar 17, 2020
Not a surprising move from our degenerate leaders. USA.has John Hopkins Research hospital which is the best research hospital in the world, Indians also have their India institute of medical sciences also one of the best and both of the countries closed there borders to foreigners yet Nigeria with death sentence hospitals like UCH and LUTH is opening their arms to foreigners.
sad sad
ProgrammingInstalling A Fully Functional Ubuntu 19.04 On Your Android Device. by Shepherdd(op):
So you just completed a Django introduction tutorial and to test your skills you built a mini web app (library, news, mini Facebook....), or maybe it's tensor flow or pytorch for you and you created a shiny new regression model or a seq2seq translation model but these applications can only run on either your PC or on the cloud and you might need to impress a potential client or your friends with your PC not available, enter Ubuntu chroot with termux.

Termux is a terminal emulator that can be installed from the play store. Alone it boasts of powerful packages such as Node, Python, clang, Java e.t.c, but you can even get more serious by installing an Ubuntu chroot on it to make possible and mobile your wildest programming dream.

Once you install termux, launch it and enter the below commands one after another.

pkg install proot wget
mkdir ~/ubuntu
cd ~/ubuntu

wget https://raw.githubusercontent.com/
NeoOli/termux-ubuntu/master/ubuntu.sh

bash ubuntu.sh


The above commands will download and prepare the tools for running Ubuntu and once you are done enter the below command to launch your Ubuntu, and on termux relaunch just cd back into the ubuntu directory.

start-ubuntu.sh

To get a GUI interface you will need vnc server but the process can be easily gotten from Google.

The possibilities of what you can achieve with these is limitless (ssh into servers, git, Node Express server, React Dev server, deep learning models, Jupyter Notebook e.t.c) and happy pythoning.
ProgrammingRe: Recommend A Place To Learn Programming Professionally In Lagos by Shepherdd(m): 11:37pm On Mar 16, 2020
Phil3Mon11:
hello guys, good morning to you, i have been trying to learn programming for a while tho but self learning its not working.
so i need a physical class where my progress would be monitored. I appreciate your suggesiions.
Check out New Horizons Ikeja Oba Akran. They teach all kinds of languages.

1 2 3 4 (of 4 pages)