• Search
  • API
  • Discussions
  • Computing & Technology
  • VPS Reviews

CodingForSpeed.COM

Menu
  • Disclaimer
  • Archive
    • Top Pages
    • List of Comments
  • VPS Database
  • SE Jobs

Simple C++ Coding Exercise – Use Lookup Table to Eliminate the Condition Checks

December 28, 2014 C/C++, general, implementation, integer 3 Comments
Simple C++ Coding Exercise – Use Lookup Table to Eliminate the Condition Checks
There is a popular IQ question, e.g. according to the first few number patterns, find the answer to the input: 1234 = 0 4567 = 1 2345 = 0 …
[Continue Reading...]

C++ Coding Example, Using Hash Algorithm to Remove Duplicate Number by O(n)

October 7, 2014 array, C/C++, general, hash, implementation, integer 1 Comment
C++ Coding Example, Using Hash Algorithm to Remove Duplicate Number by O(n)
Hashing is an important technique in Computer Science. There are many cases that you can use Hash to speed up your algorithms (e.g. by reducing from O(n^2) to O(n) …
[Continue Reading...]

How Many One’s Between Number 1 to N ?

June 28, 2014 C/C++, implementation, integer 1 Comment
How Many One’s Between Number 1 to N ?
Question: Given a positive integer (nature number) N, count the number of ‘1’s between number 1 to N inclusive. For example, when N = 2, the answer is 1, …
[Continue Reading...]

Fast Power of Two Equal or Larger than a 32-bit Integer

April 8, 2014 C/C++, general, implementation, integer, integer power No Comments
Fast Power of Two Equal or Larger than a 32-bit Integer
I have seen a naive implementation at work today (written by a colleague). My colleague intends to generate a number that is power of two, and the number is …
[Continue Reading...]

High Performance FillChar Method Comparison for 32 bit (every four bytes)

January 28, 2014 array, assembly, C/C++, implementation, integer No Comments
High Performance FillChar Method Comparison for 32 bit (every four bytes)
In C/C++, if you want to clear an array by filling a byte-value, you can use the following: void * __cdecl memset(void *_Dst, int Val, size_t _Size) This allows …
[Continue Reading...]

Counting the number of Leading Zeros for a 32-bit Integer (Signed or Unsigned)

January 23, 2014 C/C++, integer 1 Comment
Counting the number of Leading Zeros for a 32-bit Integer (Signed or Unsigned)
To count the number of leading zeros for a integer, we can use the following intuitive (bruteforce) method to increment the number of zeros until a first one (from …
[Continue Reading...]

Posts pagination

Previous 1 … 7 8 9 10 11 12 Next

RSS Computing & Technology

  • Understanding std::transform_reduce in Modern C++
  • WordPress: How to Output Full Text in the Feed?
  • Nvidia, I’m coming again — this time I’m tougher
  • Introduction to Parquet Files, Read/Write using Python
  • Implement a Lock Acquire and Release in C++
  • Cambridge Science Park: Microsoft, AMD and Raspberry Pi (Neighbours)
  • Understanding the Sigma Function: Divisors, Multiplicativity, and the Formula
  • Why Parallelism Isn’t Infinite: Amdahl vs Gustafson Explained Simply
  • Teaching Kids Programming – Introduction to Combinatorial Mathematics 1 (Pascal Triangle/Binomial)
  • The Hidden Engine of Performance: It’s All About Where the Data Lives (Cache is the King)
This domain is hosted proudly on QuickHostUK & Namesilo Domain
Vultr VPS $25 Credit
Free $25credit when you sign up with Vultr Cloud VPS (10 Months Giveaway!)

Free $20 credit when you sign up with Linode Cloud VPS (4 Months Giveaway!) - (Promotional Code: PodcastInIt2018)
Free $10 credit when you sign up with DigitalOcean Cloud VPS (2 Months Giveaway!)
Free $10 credit when you sign up with Aliyun Cloud VPS (2 Months Giveaway!)

Get more promotion deals by using VPS Database and VPS Search Tool

Tag Cloud

about us algorithm binary operation binary representation bit shift c# c/c++ cache hit cache hits collision condition checks count the number of leading zeros developer productivity exp exponential function filldword hash key implementation Infrastructure as code inline assembly introduction java KPI loop math most significant bit msb natural numbers next largest power of two O(log n) Pair Programming performance power of two prefetching Programming Language Project Management psudo random generator recursion remote working shift Software Engineering tweaks Visual Studio Code x86 assembly xorshift
CodingForSpeed.COM Copyright © 2025.
This Wordpress Theme is Schema
Donate me and I'll send you the schema theme
so it is a lot cheaper for you - win win situation! 
All rights Reserved © 2014~ 2025 Uptime 4384 Days, 69 Posts and 5 Pages, 30 comments.
Computer & Technology | ROT47 | JustYY | Is VBScript Dead? | Weibo & Miaopai Video Parser | Steem Tools | VPS Reviews | Sites @ Github
Recommendations: Disclaimer | TopCashBack UK | Quidco CashBack UK | $2.5 Vultr Cloud VPS | $5 Linode Cloud VPS | $5 Digital Ocean Cloud VPS | PlusNet Fibre | QuickHostUK | Namesilo Domain | Watch TV Online (Video Streaming) | Weibo & Miaopai Video Parser
Follow Us: Linkedin Page | Facebook Page | Twitter | Sites @ Github
Make Your Wordpress Fast Again! This Wordpress is accelerated by WP Rocket Plugin!
Advertisement