Motaibi1989 Blog

The C++ Programming Language 4th

How to convert .VHDX to .VDI VirtualBox file

Linux: vboxmanage clonemedium disk /full/path/to/inputdisk/vmdisk.vhdx /full/path/to/outputdisk/vmdisk.vdi –format VDI Windows: c:\ > “C:\Program Files\Oracle\VirtualBox\VBoxManage” clonemedium disk /full/path/to/inputdisk/vmdisk.vhdx /full/path/to/outputdisk/vmdisk.vdi –format VDI

Delphi Language Guide

Download Book Delphi Language

How to Create and Use Alias Command in Linux

List Currently Defined Aliases in Linux $ alias As you can see, executing. $ ll Is equivalent to running: $ ls -alF Creating Temporary Aliases $ alias shortName=”your custom command here” $ alias wr=”cd /var/www/html” Creating Permanent Aliases $ nano ~/.bashrc #My custom aliases alias home=”ssh -i ~/.ssh/mykep.pem tecmint@192.168.0.100” alias ll=”ls -alF” Remove an alias added via the command  $ unalias alias_name $ unalias -a […]

How to Hide Quick Access on Google Drive

1. Go to drive.google.com from your desktop browser. 2. Click on Settings Icon from top-right side. Then click Settings. 3. A Settings Pop-up will come up. Look for the Quick Access section that says “Make relevant files handy when you need them.” 4. Uncheck this option. 5. Click Done from top-right corner and refresh your browser to see changes. It should be gone.

JAVA – Search File In Folder

class SearchFileInFolder { public void SearchPath(File folder) throws IOException { File[] listOfFiles = folder.listFiles(); if (listOfFiles.length < 1) { System.out.println("\n #---This Folder Empty: "+folder.getAbsolutePath()); } else { System.out.println("\n #---List of Files & Folder: "+folder.getAbsolutePath()); for (File file : listOfFiles) { if(file.isDirectory()) { System.out.println("FOLDER: "+file.getAbsolutePath()); SearchPath(file.getAbsoluteFile()); } if(file.isFile()) { System.out.println("FILE: "+file.getAbsolutePath()); } } } } public static void main(String[] args) throws IOException { SearchFileInFolder obj = […]

‏initialize an stdarray algorithmically at compile time

static constexpr unsigned num_points{ 7810 }; std::array< double, num_points > axis; for (int i = 0; i < num_points; ++i) { axis[i] = 180 + 0.1 * i; }

Print Size of Fundamental Types

#include <iostream> using namespace std; int main() { cout << “sizeof(char) is ” << sizeof(char) << ” bytes ” << endl; cout << “sizeof(short) is ” << sizeof(short) << ” bytes ” << endl; cout << “sizeof(int) is ” << sizeof(int) << ” bytes ” << endl; cout << “sizeof(long) is ” << sizeof(long) << ” bytes ” << endl; cout << “sizeof(float) is ” […]

C++ assert.h

#include #include int test_assert(int x) { assert(x

The Linux Programming Interface