GNU Make is key utility in building applications.It is available on any operating systems. Its main purpose is to determine automatically which pieces of a program need to be recompiled, and issue the commands to build them While working with open source project, Make is the common tool because almost any IDE can work with […]
Linux users, even beginners are familiar with the simple file utilities like ls, rm, cp etc. If you look at /bin directory in any linux distribution , you will find many tools that can help on a daily use. In this post, I will cover some interesting tools. The purpose of this post is […]
If you write a complex python code , it is very important to handle errors and exceptions. While handling files, connecting to database systems and so on , you can be the best programmer in the world and still get errors that is not up to you. When you write a code for infrastructure, you […]
After covering sed in details , its also good to know awk (gawk) – a programmable stream editor Awk helps with manipulating of structured data and generating reports. awk is actually a programming language with syntax similar to C. awk Uses three ‘blocks’ of instructions: BEGIN, main loop and END and it uses similar principle of line […]
In API 27 , Google added SharedMemory class so applications can create and use shared memory using asmem (/dev/ashmem). Today, less than 1% of mobile devices work with API 27 (Android 8.1) so It is useless. In this post I will show you how to work with ashmem, creating and using shared memory between 2 […]
Writing Python code is fun and easy. You can use Procedural programming, Functional programming , Object oriented programming or any combination. Functions are basic unit in any method you choose. Functions are objects, defined with the ‘def’ statement followed by argument list. The function body is defined using indentation like other python statements def fn(a,b): […]
One basic concept of Linux (actually Unix) is the rule that everything in Unix/Linux is a file. Each process has a table of file descriptors that point to files, sockets, devices and other operating system objects. Typical system that works with many IO sources has an initializaion phase and then enter some kind of standby […]
Many functions in Python use or generate in-memory lists for iteration. This is fine for relatively small list, but for large lists it becomes a problem. Lazy Lists A lazy list is when the next item is supplied when needed, and not before. If we stop processing before reaching the end of the list then those […]