Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,152,498 members, 7,816,187 topics. Date: Friday, 03 May 2024 at 07:17 AM

Foldl's Posts

Nairaland Forum / Foldl's Profile / Foldl's Posts

(1) (2) (of 2 pages)

Programming / Re: Hello PHP Dev, If You're To Dump PHP What Language Will You Adopt? by foldl: 4:43pm On Oct 08, 2016
ladiguy:



Its a language own by microsoft .and u should know microsoft saftware is widely used accross the globe .

C# is a powerful language in it's right but basing your choice on Microsoft alone is not wise. Behemoth corporations do fall and smaller startups rise to take their place every now and then. You might be surprised to find that Microsoft isn't as popular as you think, especially as a deployment platform. More enterprise services, cloud platforms and applications are built and hosted on open source technologies than on windows.

1 Like

Programming / Re: Containers by foldl: 11:44pm On Sep 29, 2016
DonSegmond:


Nah, containers are not like chroot jail...

@DonSegmond I didn't say a chroot jail is the same as a container. The word I used was 'similar'. This is in the sense that both essentially create an isolated environment. With respect to networking I daresay a chroot can provide networking separate from the host OS. Basically, a chroot is how Linux OSes are installed. If you have installed Arch Linux for example, you'll see that after booting from the installation media and setting up your disk partitions you mount your partitions and create a chroot in the mount point of the root partition using the arch-root command. While in the chroot you can install and configure your system as you like. Rebooting without the installation media boots you into the newly installed system. I am not in anyway claiming to be an expert on this subject but what I've written above is how I understood the process after several runs with Arch installation.

PS:
- The odoo instance I mentioned was for production though it was internal.
- Give me a shinny new PC with any OS and if it ain't already on Linux it'll be in less than an hour! I've been using Linux for a decade, I can't bear to use anything else.
Programming / Re: Running Postgresql On Fedora 24 Linux by foldl: 8:19pm On Sep 25, 2016
DonSegmond:
Postgres is fully feature, more so than MySQL. It has richer data types. MySQL doesn't intend to be so. MySQL is good enough for basic websites. If you wish to build your business bet on Postgres. MySQL has reliability issues and loosing your data is a possibility that sadly plenty of people have experienced. MySQL is great for a read heavy site like a news, blog or web forum. Postgres is a solid database. It supports true ACID. Atomicity, Consistency, Isolation and Durability. So is good for sites like Banks, Auction, where every action truly does what you expect. MySQL will truncate your data if you give it what it doesn't expect, meaning, it silently fails. Postgres will return an error, letting you know you are violating your data. The rumor that Postgres is not fast is a wash, I have a Postgres database with few billion records that get's pounded on every damn second for that last 5 years and it's holding up fine.

+1 for Postgres. I recently discovered you can't even create an index on a mysql VARCHAR/CHAR column if the length of the column is longer than 200 characters. Full text search in mysql is also not nearly as advanced as in Postgres. Your applications can also natively query data stored in other databases (eg oracle, mysql, mssql etc) through Postgres as if the data was stored in Postgres using Postgres' foreign data wrapper feature.

Mysql/mariadb is no way near Postgres in features and performance.

1 Like 1 Share

Programming / Re: Containers by foldl: 8:01pm On Sep 25, 2016
Use docker. I once deployed an odoo instance using docker containers. They are also useful for isolating development environments without bloating your system. Sadly, there isn't much advantage in using docker if you're on Windows. You'd be better off with Vagrant in that case. Docker containers are light because they reuse the kernel of the host OS and since you can't reuse the Windows kernel for a Linux container you'd have to use virtualization (virtualbox, VMware etc). Containers are very similar to creating a chroot jail.
Jobs/Vacancies / Re: Andela: IT Training And Job by foldl: 3:38pm On Sep 11, 2016
Umu101:

The key to passing this test is simple: Stay away from the CHURCH!!. don't let them cast the PYTHON out of you!!!!.
I can't take it (Add meme here)! You are friggin hilarious!
Jobs/Vacancies / Re: Andela: IT Training And Job by foldl: 3:29pm On Sep 11, 2016
Umu101:

looking for a hint from me!!
From my posts you will know that I am not a coding genius.
I wrote most of my codes on paper. (bug ridden codes)
I had to use insecticide!!!
I am still at 88%.poor power, internet connectivity and the high cost of Baygon are really affecting me.

Guy dey way you dey mek me scatter laugh if I bust my bele I go invoke Amadioha for your head oO!
Programming / Re: Please I Get This Error When Submit Form (notice: Undefined Index) by foldl: 9:13am On Sep 03, 2016
nicolas247:
Why is everyone just looking and pass

Because they can't read your code! Always use tools like hastebin.com or github gists when you want to share snippets of code. I don't want to strain my eyes reading through lengthy code without the benefit of proper syntax highlighting just because I want to be helpful.

2 Likes

Programming / Re: Mysql: I Find This Silly...pls Help Me Out by foldl: 9:25pm On Aug 31, 2016
logicalhumour:
but if I do this, am I not ...like allowing port 80 to access my computer?. If its hosted, wouldn't port 80 have to communicate with something outside the server which is my physical computer?


Depending on your server configuration (Apache, NginX, lighttpd, iis) only files in your webroot or the document root specified in you virtual host configuration are served on port 80 (or any port that your web server has been configured to use). If your site's config file is located outside those locations it can still be accessed (ie required or included) by your php scripts.
Programming / Re: MySql: Is It Advisable To Create Users In This Way Using Mysql? by foldl: 11:41am On Aug 30, 2016
@logicalhumour I suspect you're trolling but I'll answer your question in the off chance that you're not.

That is how you create a user in mysql but not quite in the same sense as creating a user account for users on your site. Creating a user in this manner is similar to creating a Windows user (I.e. the type you use to login to your laptop after booting) for every user of your site. So, in reality you only need just one (or a couple for things like replication, backup etc) such mysql user.

Your website will then use this one mysql user to connect to the mysql server. In addition to having this mysql user you must create a database in mysql and explicitly grant access to that database to this user. Within this database you also must create a table in which the actual login credentials of users of your site will be stored.

To recap, use the mysql user account to connect to a specific database on your mysql server. When connected create a record in a table with username and password for your site's user.

PS: For one who claims to have 'years as a programmer' and given your username it is hard to believe that you're not just trolling with this question. However, am glad to be punked.
Programming / Re: Mysql: I Find This Silly...pls Help Me Out by foldl: 11:03am On Aug 30, 2016
logicalhumour:
I want to log my user in on my site... the username and password are in a table of my site's database

Now I'll have to login with root (for instance ) because it has enough permission to carry out the operation. ie
mysqli_connect ('host', 'username', 'password')
to check this table and retrieve data …but that would appear in my source code. Help me out please. Thanks

1. Store your connection parameters as environment variables and read them in with the getenv function.
2. Store your connection parameters in a php file outside your server's webroot (not in www or any sub folder inside www), i.e. the file containing the parameters should not be accessible to anyone visiting your site in the browser. Require this file in the source file where you need to use the parameters.
Programming / Re: PYTHON: Please If You've Used The Python Sqlite3 Module Successfully, Help Me by foldl: 11:08pm On Aug 23, 2016
Please read about Python's DB API specification at https://www.python.org/dev/peps/pep-0249/
.

It is a uniform API for all standards compliant database adapters for Python.
Programming / Re: Python Vs C# by foldl: 6:35pm On Aug 23, 2016
pythonkid:


no one can master even html in 5 years not to talk of python in 4 months , wtf , master python ??

C# is fast compared to python
python is platform independ compared to C# which runs only on .net platforms
its easier to make GUI for C# programs compared to python that needs a framework for that
python is good for writing network realated apps
....
you have to tell us what you aim to achive then we will tel you what language will be better , but if you
just want to learn programming then go for C# ..

C# is fast compared to python... Really?
Do you have any data/benchmarks to back this up? I am not saying Python is faster but I am not accepting your claims without hard data either. I do know that C# programs are compiled into MSIL (Microsoft Intermediate Language) and then interpreted at runtime but so also is Python compiled to byte code and then interpreted.

Secondly, C# runs just as well on Unix/Linux as it does on windows. Microsoft recently open sourced the core .NET framework on which C# is based which means you'll be using exactly the same libraries on other platforms. Even before that the mono runtime (now developed by Xamarin) provided an almost feature complete replacement for .NET.

Thirdly, even C# requires frameworks for GUI development (WinForms, WPF). By far the best framework I have used for GUI development is QT which has excellent bindings for Python (PyQt, PySide). Other frameworks like Gtk, Tkinter, Wx can also be used with Python. If you need drag and drop you can always use QT Creator, Glade or Wx Builder. Which is easier? Depends on who is using it.

Final words...
Language X is better than language Y is usually a beginners argument and is wont to cause flame wars. When you've built software professionally for some time you get to a point when you don't care about which language is better but which one gets the job done in the most efficient and timely manner, most times it will be the language you're most competent in but not always.

3 Likes

Programming / Re: Need Help On A Project by foldl: 6:00pm On Aug 23, 2016
When in doubt try Python!
Programming / Re: What's Your Favourite Text Editor? by foldl: 2:00pm On Jul 09, 2016
KazukiIto:


Thank you. But I belong to the Cult of Vi now. Actually I use Vim. Not as sophisticated as Emacs, but I'm faster with it.

You have backslided bro. You must go to father Richard Stallman (St. IGNUcious) to confess your sins and perhaps receive a fresh baptism into the Church of Emacs. Anything other than that is blasphemy!
Programming / Re: What's Your Favourite Text Editor? by foldl: 10:11am On Jul 08, 2016
KazukiIto:
My best editor is definitely Emacs. One of the most powerful editor out there...

A well configured Emacs is actually the best IDE (I mean IDE not editor). The best thing is you can use it for any programming language without having to change your IDE or workflow.

If you love to have the best IDE and you love Emacs then give your Emacs super powers by installing spacemacs (http://spacemacs.org). Remember to enable your preferred layers in ~/.spaceman's and thank me later.
Programming / Re: Yii2 Rest API Question by foldl: 1:57am On May 15, 2016
When you extend \yii\rest\ActiveController you do not need to render your result but return it directly.

In your example change '$this->render($model);' to 'return $model;'. Also note that since you are using findOne it will return the first record in that table only.

In general, you should return any value or object instead of rendering when using rest controllers. You don't need to serialize the data into json as that is done implicitly by the \yii\rest\ActiveController class. When in doubt read the source code!

I built a production system with yii2 when it was still in beta. I even found and fixed a bug and sent a pull request which was merged. But I haven't written any code in months so I might be a bit rusty. grin
Education / Re: 7 Benefits Of Attending A Public University by foldl: 7:47pm On Apr 26, 2016
CaptainECole:
I beg to disagree, there are lots of private universities that have just 5 profs,
I don't know what you're saying but 80% of private unis in Nigeria lack adequate amount of professors.. #Fact

In that case the blame should rest squarely on the NUC for allowing them operate. No other agency of the government can decide the health of any university in Nigeria but NUC. If the NUC gives any institution a clean bill of health nobody has the power to say otherwise.

Let p1 and p2 be two kinds of label (say Mimee and Indomie) of a particular product (eg noodles). Given that the actual product bearing those labels are made from the same factory line with more or less the same ingredients. Will you say the products bearing the label p1 are better than those bearing p2? Support your answer with some evidence.

The professors that teach in public universities are the same that lecture in private ones. Even those other lecturers in private universities who are not professors are products of public universities. Unless you are telling me that people who receive education at public universities are not good teachers then you don't have a case.
Education / Re: 7 Benefits Of Attending A Public University by foldl: 6:36pm On Apr 26, 2016
CaptainECole:

... as compared to the private universities which have limited or no professors...

One condition for accreditation of any department by the NUC is having at least two professors in the department. Also, the fact that it is the same NUC that accredits both private and public universities and bearing in mind that such accreditation is based on the same benchmarks it will not be correct to say that one is significantly better than the other.

Moreover, most private universities are owned by big churches with quite deep pockets and can afford to attract world class academics with fat salaries and research grants.

I am a product of the public university system and currently teach at a federal polytechnic so I am just posting this to correct some wrong assumptions rather than defend private universities.

1 Like

Romance / Re: Breaking News: Prince Is Dead!!!!!! by foldl: 7:03pm On Apr 23, 2016
nubian999:
don't derail the thread it is about prince so open a thread for these ppl if you like grin



OK, RIP to Prince!
Romance / Re: Breaking News: Prince Is Dead!!!!!! by foldl: 6:55pm On Apr 23, 2016
nubian999:



Lol! Nigerians Just Love to argue grin grin grin grin


dude! Prince is a celeb and those people you mentioned... God knows!! LOL If you know Micheal Jackson then it's enough for us. thank you

Trust me those are also celebs in their own right. SPJ and Wadler are world renowned computer scientists and mathematicians. SPJ created the Haskell programming language in which Facebook's haxl library and project sigma are implemented. Both SPJ and Wadler have made significant contributions to math and computer science. The other two names are celebs in your sense of the word but just not in your radar.
Romance / Re: The Legendary Hero Dagrin A.k.a Barrack O' Grin by foldl: 9:02pm On Apr 21, 2016
RIP to the legend!

... I be bad boy but I get loyalty, I no want hear story when marketer go pay me royalty...

Naija's very own Lil Wayne.
Romance / Re: Breaking News: Prince Is Dead!!!!!! by foldl: 8:53pm On Apr 21, 2016
tommychow:
Some nigerians are bloody ignorant villagers. How can you not know Prince? Smh

RIP, Prince. You stood out at the time when it was hardest for black musicians. Goodbye, brother.

Do you know Simon Peyton Jones or Philip Wadler? Do you even know Nicodemus Mbatsavtampu or Gbia Dyege? If you don't know any of these people without googling then you are just as ignorant as everyone else. In fact, even Google can't help you with the last two names! The so called village ignoramuses you are calling out will probably teach you a thing or two. People know more about events and people associated with their interests and as interests differ it is foolish to think less of people simply because they have different interests than you. You had exactly zero reason to call a whole swarth of people villagers and ignorant just because they don't know who some inconsequential fellow is. Inconsequential is used here not to belittle your Prince but to state that knowing who he is doesn't add any value to my life one way or another.

31 Likes 7 Shares

Programming / Re: Data Scientists In Nigeria, Lets Talk by foldl: 5:50pm On Mar 13, 2016
lum1:
Hopefully, my definition is close to what the OP has in mind

This sounds very much like Machine Learning to me.
Politics / Re: Senate Reveals Mtn’s N300bn Proposal As Settlement For Fine by foldl: 10:21am On Mar 11, 2016
Elose11:

This would come by way of MTN Nigeria committing to purchase N80 billion of Nigerian sovereign debt issued on the international market in 2016-2017.

Am I the only one to notice that MTN proposes to pay a debt by making an investment of #80 billion for which it will fully receive a return of its capital with interest? By the way sovereign debt is another name for government bonds or treasury bills, which are by far the safest investment with guaranteed returns.

What MTN is proposing can be compared to the following: I owe you 100 naira but decide I'll pay you only 40 naira. Out of the 40 I've decided to pay, you must agree to accept 10 naira worth of goods from me whether you need them or not. After that I'll pay you 18 naira in cash and then I'll use the remaining 12 naira to buy goods from you which I'll resell at a profit! This really means I've only paid you 28 naira out of the 100 while at the same time making great profit.

But I got F9 in economics sha, so any clarification by the economists here will be appreciated.

2 Likes 1 Share

Programming / Re: Pls Programmers Help With Similarities Of Pseudocode & Algorithm by foldl: 2:55pm On Mar 09, 2016
The question is not a very clear one. Your question is akin to asking for the similarities between a dog and an Alsatian. A dog is a category of animals while an Alsatian is a kind of dog, but we also have Rottweilers, spaniels etc.

An algorithm is a finite set of instructions that, if followed, accomplishes a particular task (Ellis Horowitz et al, 2014). Algorithms being a set of instructions must necessarily be conveyed (or represented) in a way that is clearly understandable. One of the ways in which algorithms are expressed is by use of pseudocode. Algorithms can also be expressed using flowcharts, Gantt charts etc. So there is no similarity per se in algorithms and pseudocode. The relationship between the two is that one is a representation of the other.
Politics / Re: Ben-Bruce Mocked Buhari With The Age Of His Ministers(Photos) by foldl: 4:55pm On Feb 12, 2016
I can suggest two people that shouldn't be ministers in this administration. The first is that old man from Oyo who said he didn't want to speak ill of Boko Haram because he was scared for his life and the other one whose name rhymes with lie. That doesn't mean I don't believe that Buhari was the lesser evil and so the best choice in the last elections.
Programming / Back2back by foldl: 6:55am On Jan 30, 2016
Every abstraction in functional programming was a hit back to back, from type classes to monads, from higher kinded types to higher order functions, from lazy evaluation to currying, from applicative functors to Control.Monad.Cont, from MVars/TVars to STM (Software Transactional Memory). Iyalaya anybody FP ati take over, f^ck that shít! **drops mic

Go Haskell or go home!!! grin grin grin
Programming / Re: Why Are Nigerian Programmers So Dumb? by foldl: 5:18pm On Jan 17, 2016
aitoehigie:
...which i am in the process of deploying on Amazon's EC2 and S3 (if you know what that is).

dis wan dis pikin jus dey tro amazon around like say im jus learn about am yesterday. Egbon Seun abeg no mind am na small pikin dey worry am.

him never go live e dey yarn panya. Wetin original for e-payment wen interswitch, pay4me, remitta, netpostpay, gtpay etc full ground, mek I no mention stripe dem. No worry, sebi u think say na to write code dem dey tek create e-payment for naija, wen the cbn and other policy huddles hit u u go begin look for pesin wey you go dash the code sef.

BTW, upon d mouth wey u dey mek I doubt say you fit mek wetin Seun dey mek for 1 month in adverts for 2 years.

Seun code na cut and paste but e dey pay wella!

7 Likes

Programming / Re: Why Are Nigerian Programmers So Dumb? by foldl: 4:46pm On Jan 17, 2016
aitoehigie:
I did not start this thread to start a "flame war"...

For one whose intent was not to start a flame war you sure picked a controversial title for your post.

2 Likes

Programming / Share Links To Interesting Tech Articles Here by foldl: 4:04pm On Jan 17, 2016
Have you read any interesting blog posts lately? What's that shiny new tool or framework you've fallen in love with and wished others knew just how awesome it is? Where is your favorite place to find news about your favorite language or platform? Please share it!

Here are a couple to set the ball rolling:
www.reddit.com/r/haskell
www.andrewhfarmer.com/getting-started-tutorials/

PS:
Keep it as strictly programming as possible.
Programming / Developers, Share Your Github URL! by foldl: 3:48pm On Jan 17, 2016
Hey devs, come share your GitHub/bitbucket URL!
Mine is https://github.com/abrahamy?tab=repositories
Programming / Re: Your Help Is Needed In My Final Year Project by foldl: 3:06pm On Jan 17, 2016
proxy20:
...go to www.parse.com and get the api key and some details...

+1 for parse.com, it makes it possible to build a mobile app without worrying about building the back end from scratch.

A similar approach to parse.com would be to use CouchDB as your back end leveraging its restful interface and a tool like PouchDB for the client. However, this assumes that your mobile app will be written in JavaScript using something like react-native or ionic. If you wish to follow this approach you can setup free CouchDB instances on www.iriscouch.com

(1) (2) (of 2 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. 86
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.