Today's Question:  What does your personal desk look like?        GIVE A SHOUT

SEARCH KEYWORD -- effect



  Understand GoLang WaitGroup internals and how it works

Background Before getting into the main content, let me give a brief introduction to WaitGroup and its related background knowledge. Here, the focus is on the basic usage of WaitGroup and the fundamental knowledge of system semaphores. For those who are familiar with these, you can skip this section directly. WaitGroup WaitGroup is one of the most common concurrency control techniques in Golang, and its function can be roughly compared to the join() in concurrency control of other languages' mul...

   GOLANG,WAITGROUP,SOURCE CODE     2023-04-26 08:02:01

  Why Dynamic Programming Languages Are Slow

In a statically typed language, the compiler knows the data-type of a variable and how to represent that. In a dynamically-typed language, it has to keep flag describing the actual type of the value of the variable, and the program has to perform a data-dependent branch on that value each time it manipulates a variable.  It also has to look up all methods and operators on it. The knock-on effect of this on branching and data locality is lethal to general purpose runtime performance. T...

   Dynamic language,Slow,Analysis     2012-03-26 15:33:11

  Best practices of front end optimization

1. Use DocumentFragment or innerHTML to replace complex elements insertion DOM operation on browser is expensive. Although browser performance is improved much, multiple DOM elements insertion is still expensive and will affect the page load speed. Assume we have an ul element on our page, we now want to retrieve a JSON list using AJAX and then update the ul using JavaScript. Usually we may write it as : var list = document.querySelector('ul'); ajaxResult.items.forEach(function(item) { // ...

   JavaScript,Front end,Optimization,Tips     2013-07-06 11:26:27

  JavaScript interview questions

This post will cover the JavaScript questions I have encountered and have seen during my programming career. They will mainly focus on vanilla JavaScript though there are lots of excellent frameworks out there and many people are using them in their daily work. this keyword this keyword is an very important but easy to confuse concept in JavaScript since it is always referring to the calling object of the function. 1. What will be the output of below code snippet? function User(name) { this....

   JAVASCRIPT,ALGORITHM,THIS,CLOSURE     2019-03-09 07:05:46

  Hey kids, just say NO to programming !

Cory Doctorow's latest talk 'The Coming War on General Purpose Computing' really puts things in perspective about life in the 21st century. This got me thinking more about functional programming languages and how they are related to the intentional limitation/crippling of turing machines by industry and government. What if Stallman is right about the intentional efforts to limit freedom of information ? What if it's even worse than we all think it is ? In relation to functional languages ...

   Programming,Factor,View,Kids,No     2012-01-16 10:16:19

  Debunking the Google Interview Myth

Years ago, rumors used to circulate about Microsoft interviews.  They were the hot, new company that everyone wanted to work.  With envy came the urban myths.  These rumors have since been transfered to Google, and will surely be transfered to some new company in due time. Bloggers – always desperate for links and traffic – have capitalized on this, with scary articles about their “nightmare interview” and “crazy questions“.  Let’...

   Google,Microsoft,Business insider,Interv     2011-04-26 10:09:53

  How much money do you *really* need to start your company?

I keep hearing startup entrepreneurs tell me “We need funding. If we just had $XXXk of investment, we’d be killing it right now.” I press them with one question: what would you do with the money if you had it? Inevitably the question is met with a blank stare. Most of the time people haven’t thought about it. The answers that do come feel a little half-baked:“Buy a bunch of ad words to get people to our site – that’s all we need”“Build th...

   Business,Startup,Investment,Money,Ad     2011-09-26 11:16:35

  Impact of AI on UI/UX design

The growth of computerization and Artificial Intelligence implanted into our regular daily existences in the course of recent years is only productive, we're no longer talk about fantasy since machines are going on at this very moment. This quick advancement has propelled a radically new age of designers to search for client-focused arrangements through the extent of these innovations. Along these lines, we need to investigate what this implies for UX plan in 2018 and what standards we should gr...

   UI,AI,UX     2018-11-28 07:05:26

  Mock Solutions for GoLang Unit Test

In Go development, Unit Test is inevitable. And it is essential to use Mock when writing Unit Tests. Mock can help test isolate the business logic it depends on, enabling it to compile, link, and run independently. Mock needs Stub. Stub function replaces the real business logic function, returns the required result, and assists the test. I involved the related test code for Controllers while writing Kubernetes Operator recently, and there would be mocks for GRPC and HT...

   UNIT TEST,TESTIFY,GOSTUB,GOMOCK     2020-10-31 21:59:15

  The Wasteful Legacy of Programming as Language

A few years ago I visited a friend who is a graduate student in linguistics. After some time he asked me if I was aware of the work by Chomsky on formal languages. I told him that yes, Chomsky work was a basis for much of the developments in theoretical computer science. More than that, I was glad to learn that there was something technical that I could share and discuss with other people in linguistics. At the time I found this was just a great coincidence. It was only recently, though, t...

   Programming language,Human language,Chomsky     2011-11-28 10:36:34