Posts

Do You Know How Many Tasks JavaScript Can Process in One Second on Your Computer

 Here is a program to see how many tasks JavaScript can process in one second on Your Computer function JavaScriptSpeed(){ var count = 0; function add (){ count = count +1; } var now = Date.now(); while (Date.now() - now< 1000 ) { add(); } console.log(count); }; JavaScriptSpeed(); Approximately  10379015 times in my computer . In one second JavaScript can call the  add  function  10379015 times or in other word 10.3   million times! You can check on your computer by Copy-pasting on your browser.  

How to make simple HTTP server using Python

Image
Here is the way .... 1. 2. Keep the file on Python Folder. 3. Type http://localhost:8000 on your browser 4. Surf on local machine

Why wrapping in the jQuery object

So here's my answer: $(function() { $('img').attr('src', 'http://placepuppy.it/350/150'); }) I'm simply starting with the jQuery object and passing it an anonymous function. The anonymous function changes the  src  of the one  img  on the page to the URL provided. (Remember, $('img')  grabs  all  of the images on the page, so this is a  very bad  selector. It works in this case because there's only one  , but normally you should use a much more specific selector.) If I hadn't wrapped my  .attr()  function in the jQuery object, it would run as soon as it's loaded in the  of the document, which occurs before the   tag appears on the page. So nothing would happen. But by wrapping it up in the jQuery object, it runs when the DOM is ready and I get to see a cute puppy instead! Source 

How to reset Password for Teletalk MiFI or ZTE MF65 Router

The default password is password or admin depending on your carrier.  If you have changed and forgotten  the password then you need to restore the device to factory defaults:  From the powered up state press and hold the power key and the WPS  key together for 8 seconds until the power LED goes off. The device will  reset. Source  

Google launches Google Fit app

Image
Google launches Google Fit app for Android, keeping all your fitness data in one place and that can be a great answer to Apple Health   Google Fit will track everything, while serving up stats of your week-to-week and day-to-day activities like Apple Health. You can integrate different apps like  Nike, HTC, LG, RunKeeper, Withings, Motorola, Noom, Runtastic and Polar. Suppose you o prefers to use the Runtastic Orbit fitness band when running and a Moto 360 smartwatch the rest of the time, you can centralize all their data within Google Fit. So have a look.

Do you know why your recorded voice sound is different to you?

We hear sound through two pathways.  The first is air conduction. In air conduction sound passes through the air and into the ear canal, where it vibrates the eardrum. These vibrations are transferred to a sensory organ – the cochlea – through a chain composed of three tiny bones: the malleus, incus and stapes. Secondly we also hear through bone conduction, – at least, we hear our own voices. When we speak, vibration of the vocal cords engenders a companion vibration in the bones of the skull, stimulating the cochlea. This pathway augments the air conduction pathway. But when we hear our own recorded voice the bone conduction pathways is eliminated and sound is different to you.

While loop VS for loop in PHP

For loop for (start value ; End value; Increment){ //do something } Example: for ($a = 10; $a "; } While loop start value while (End value){ //do something Increment } Example: $a = 10; while ($a "; $a = $a +10; }