SEARCH KEYWORD -- TYPE
Learn Emacs: Keyboard Macros
An emacs keyboard macro is just a recording of user input into emacs, which means that most anything you can do in emacs can be recorded as a macro. Read that again. Pretty powerful.Here’s how it works. To start recording, typeC-x (and input the commands in your macro. Then typeC-x )to stop recording. Then typeC-x eto apply the macro once, orC-u 0 C-x eto apply the macro until the bell rings or end of buffer is reachedKeep in mind that you must not ring the bell when defining a keyboard m...
Get associated file icon with only extension name using C++ on Windows
I have searched on Google for a few examples on how to get associated file icon with only file extension name using C++ on Windows. There are some useful information provided on MSDN which explains the use of SHGetFileInfo() function.It also gives an example code, but it doesn't say how to do it with only the extension name. Here I give an example code on how to achieve this after I gathered and summarized some useful information from Internet. I have tested the code on my PC, it w...
File icon,Windows,Association,Extension name,C++ 2012-03-26 09:55:20
Removing duplicates in sql
In modern web development, it’s standard practice to make use of a database abstraction layer, typically an Object-Relational Mapper based on either the Active Record pattern or the Data Mapper pattern. There are several pros and cons to this which are fairly well established, so I’ll spare us all from enumerating them all right now. One established pro worth mentioning is that these systems typically provide a high level interface for fetching data, often removing the need to ...
SQL,Duplicate,Remove,Web design 2012-01-05 08:20:13
new() and make() in GoLang
GoLang is a modern, statically typed, compiled programming language designed for building scalable, concurrent, and efficient software. It provides various built-in functions and features that help developers write concise and efficient code. Among them are the new() and make() functions, which may appear similar at first glance but serve different purposes in GoLang and are crucial for memory allocation and data initialization. In this blog article, we will explore the differences between the n...
Be careful about printing error as string in GoLang
In GoLang, we can format and produce string using fmt.Printf(), just like C, GoLang also supports format verbs like %s, %d which can be placeholder for different types of values. But please pay attention when printing error as string so that you will not fall into some trap. Let's first take an example code snippet and see what trap we are talking about. package main import "fmt" type A string func (a A) Error() string { return fmt.Sprintf("%s is an error", a) } func main() { a := A("hello...
STACKOVERFLOW,GOLANG,FMT 2019-01-23 09:17:15
Will nil == nil be true in GoLang
There is some interview question may ask whether nil == nil be true in GoLang. Wil it be true. false or compilation error? To know the answer, some knowledge about nil in GoLang needs to be explained first. nil definition According to Go's official documentation, the definition of nil is // nil is a predeclared identifier representing the zero value for a // pointer, channel, func, interface, map, or slice type. var nil Type // Type must be a pointer, channel, func, interface, map, or slice type...
GOLANG,NIL,NIL EXPLANATION 2021-08-08 02:54:15
Evolution mail configuration with Hotmail on Ubuntu
Evolution mail now is the default Email client on Ubuntu. When we configure this mail client with Hotmail. The steps should be followed. Step 1: Open Evolution mail through Applications->Internet->Evolution mail Step 2: Goto Edit->Preferences Step 3 : Click Add button or double click on the added mail account. Step 4 : On the Identity tab, fill the Hotmail account you want to use. Step 5 : On "Receiving email" Tab, ...
Ubuntu,Evolution mail,Hotmail,Configurat 2011-04-28 09:24:01
Understand more about Go basics with one interview question
First, let's take a look at below Go interview question: package main const s = "Go101.org" // len(s) == 9 // 1 << 9 == 512 // 512 / 128 == 4 var a byte = 1 << len(s) / 128 var b byte = 1 << len(s[:]) / 128 func main() { println(a, b) } What would be the output in your mind? The output would be 4 0. Surprising? Before getting to the output values, some concepts in Go need to be introduced and explained in more detail. len() len() is a built-in function in Go to get t...
GOLANG,CONSTANT,SHIFT OPERATION,LEN() 2020-10-10 02:52:19
Which program is using USB device?
Sometimes when we want to plug out our USB device, but the operating system tells us we cannot plug it out since some other processes are using the USB device. How do we know which process is using our USB device. Here is a simple solution.First, go to Start->All programs->Accessories->System Tools->Resource Monitor. (as in Windows 7, for other Windows systems, you may similar program called Resource Monitor but may not in the same location as in Windows 7).Then, open Resource Monito...
Windows.ISB device,Plugout problem,Solut 2011-07-22 09:20:13
Can a == true && a == false be true in JavaScript?
JavaScript is a weak typed language and it has a loose comparison feature where two objects/values of different type can be compared using == operator. This provides developers great flexibility and confusion at the same time. Before understanding how == works in JavaScript, can you first answer the question in the post title? Can a == true && a == false be true in JavaScript? Normally, we would think that this expression will always return false since a can be either true or ...
JAVASCRIPT,COMPARISON,INTERVIEW QUESTION,== 2018-03-25 03:39:43
RECENT
- Private LLM Integration with RAGFlow: A Step-by-Step Guide
- First Touch on OpenAI API
- Special ARP Uses: Gratuitous ARP, ARP Probe, and ARP Announce
- SIEM Big Data Visualization [04] : Data Transmission Latency SIEM Log Analysis Dashboard
- How to make select in WinSock exceed the 64-socket limit
- EtsiosApp Release Date: All You Need to Know
- SIEM Big Data Visualization [03]:Graph-Based SIEM Log Analysis Dashboard
- How AI is Changing Web Development: A New Era of Digital Innovation
- SIEM Big Data Visualization [02]: National Cyber Threats Dashboard
- Exploring the Impact of a Loan Origination System on Financial Institutions
- more>>