difference between php integer division and c integer division
We know the result of C integer division is an integer: 1/2=0, 1/3=0, 3/2=1. To get the remainder of integer division, you need to use %. To get the float […]
We know the result of C integer division is an integer: 1/2=0, 1/3=0, 3/2=1. To get the remainder of integer division, you need to use %. To get the float […]
C programmer knows how to display float 2 decimal places with printf. In php, how to round float to 2 decimal places? It is definitely necessary to echo float with […]
What is WordPress shortcode? WP shortcode is what you put in [] in your post. For example, if you write [dateoftoday] in your post, the dateoftoday is a shortcode. Why […]
The usual way to use QNetworkAccessManager and QNetworkReply is: QNetworkAccessManager nam; voif fun() { QNetworkRequest request; request.setUrl(QUrl(“https://myprogrammingnotes.com”)); connect(&nam,SIGNAL(finished(QNetworkReply*)),this,SLOT(replyFinished(QNetworkReply*))); QNetworkReply *reply=nam.get(request); } void replyFinished(QNetworkReply* reply) { reply->readAll(); } According to https://doc.qt.io/qt-5/qnetworkaccessmanager.html, you […]
Bash function looks strange for people who are familiar with other programming languages such as C++, JAVA, etc. First, you seem to never see a bash function that has (formal) […]
How to build a shared library using gcc/g++? Building a shared library with gcc is easy but it takes 2 steps: gcc -c -fpic mytools.c gcc -shared -o libmytools.so mytools.o […]
When we talk about compatibility, three objects/entities are involved. We say object2 is compatible with object1 if object3 that uses object1 is still working when it switches object1 to object2. […]
Why need to define macros in Qt project file? I have a tool source library. The library contains several header files and source files. I used conditional compilation in both […]
php iconv is an interesting function that can convert a string from one charset to another. $text=”abc”; $text = iconv(‘utf-8’, ‘us-ascii’, $text); In the above example, since the source file […]
I did not really understand google api despite the fact I’ve already developed several apps that use google apis, even in different languages such as php, python, c++, and javascript. […]