Why std::vector is the Optimal Choice for Data Structures for Performance in C++

Posted on

In C++ programming, data structures are essential for organizing and manipulating data. When it comes to storing and manipulating data, one data structure stands out above the rest – the std::vector. Efficient Memory Allocation One of the primary benefits of std::vector is its efficient memory allocation. std::vector uses contiguous memory allocation, which means that the
Read more

Sorting Two Lists Together According to The Order of One List in Python

Posted on

We may use two lists to store the values of two properties of a list of elements in Python. Under such data structure arrangement, when we need to sort the properties from one list, we may want to also make sure the other list will be also re-ordered following the same order as the first
Read more

Linux Kernel 4.19.178 Release

Posted on

This post summarizes Linux Kernel new features, bugfixes and changes in Linux 4.19.178 Release. Linux 4.19.178 Release contains 248 changes, patches or new features. In total, there are 239,909 lines of Linux source code changed/added in Linux 4.19.178 release compared to Linux 4.19 release. To view the source code of Linux 4.19.178 kernel release online,
Read more

Add Inline Comments for Multi-line Command in Bash Script

Posted on

In Bash script, it is common that multiple small commands run together connected by pipes (|) and the whole command is quite long. For clarity, we may write the command in multiple lines. How to add comments for these long multi-line commands? In Bash, the content after # in a line is the comment. Using
Read more

Thunderbird Addons to Make Thunderbird Easier to Use

Posted on

Thunderbird is powerful and feature rich. But different users have different needs and it is not feasible to include all features into the base software, where a plugin system shines. Thunderbird, similar to Firefox from Mozilla, supports addons/plugins and has a large ecosystems. Here, we will introduce several addons to Thunderbird that make Thunderbird easier
Read more

How to get the highest temperature from all sensors in a server on Linux?

Posted on

It is useful to monitor a server node’s temporary. Among all the sensors’ temperatures, the higher one may be a very important one. How to get the highest temperature from all sensors in a server on Linux? You can use this command to get the the highest temperature from all sensors in a server on
Read more

What are the best academic citation tool

Posted on

What is the best academic citation tool does anyone help? Here, we list 2 choices that are open source, or free, or have free plans. Zotero Zotero is open source and developed by an independent, nonprofit organization. Zotero can help you collect, organize, cite, and share research. Zotero can automatically senses research on the web.
Read more

How to sort all files recursively by modification time in a directory on Linux?

Posted on

How to sort all the files in a directory and subdirectories recursively by modification time on Linux? You can make use of find (GNU find, or plus stat), sort and sed together to achieve recursively sort files by modification time: find . -type f -printf ‘%T@ %pn’ | sort -k 1 -n | sed ‘s/^[^
Read more

How to sort a file by hexadecimal numbers on Linux using sort command?

Posted on

The sort command has a -n option to sort a file by numbers. However, it does not work with hexadecimal numbers. For example, this file: 400000000 __crt0 400000039 __newr0 400001B14 get_my_task_id 400001C14 get_new_task_id 400001582 input_char 40000166E input_q 400001A5D input_q_exit 400002002 main 4000000DB output_char 400001134 output_char_str 40000100C output_id 40000018F output_q 400000614 output_q_digits 400000B7E output_q_hex 400000D3E output_q_hex_j1
Read more

How to find files in a directory that are larger than certain size?

Posted on

I have many files under a directory. How to find those files under the directory that are larger than certain size, say 500MB? Find the files that are larger than 500MB in the current directory (./): find ./ -size +500M Prints our more information about these files: find ./ -size +500M -exec ls -lh {}
Read more

Thunderbird Tips: Default Descending Email Sort Order and Inline Quote When Reply

Posted on

Thunderbird is a great email client and what make it special is deeply configurable like Firefox. For me, I like to view email in the descending sort order and inline quote relied email content when replying emails. Let’s look at how to set the default order as descending sort order and quote mode as inline
Read more

Setting up Stable Xen Dom0 with Fedora: Xen 3.4.3 with Xenified Linux Kernel 2.6.32.13 in Fedora 12

Posted on

This is the latest stable and recommended stable Xen Dom0 solution on Fedora 12. No serious bug found till now and we will fix the bugs by ourselves if some appears. It also works on Fedora 14 as well. It should not be hard to use this solution on other versions of Fedora or other
Read more

PUMA: A MapReduce Benchmark Suite

Posted on

MapReduce is a well-known programming model designed for generating and processing large data. There are various MapReduce implementations. One widely known and used one may be Hadoop. Benchmarking MapReduce frameworks gets to be important. Faraz Ahmad et al. developed a benchmark suite: PUMA MapReduce Benchmark. During our work on MapReduce, we developed a benchmark suite
Read more

Hadoop TeraSort Benchmark

Posted on

TeraSort is one of Hadoop’s widely used benchmarks. Hadoop’s distribution contains both the input generator and sorting implementations: the TeraGen generates the input and TeraSort conducts the sorting. Here, we provide a short tutorial for using the Hadoop TeraSort benchmark. TeraGen generates random data that can be used as input data for a subsequent running
Read more

Hadoop Installation Tutorial (Hadoop 1.x)

Posted on

Update: If you are new to Hadoop and trying to install one. Please check the newer version: Hadoop Installation Tutorial (Hadoop 2.x). Hadoop mainly consists of two parts: Hadoop MapReduce and HDFS. Hadoop MapReduce is a programming model and software framework for writing applications, which is an open-source variant of MapReduce that is initially designed
Read more