> Why didn't they chose 12 as a number of hours, and not 10? Or 8? But as it is, we have hours, minutes and seconds, and our whole physics and other sciences revolve around those units.
Use of bases 12, 24 and 60 originates from the Babylonian time. Those numbers have a high number of divisors (relative to their values). More specifically
- 12 is the smallest number that can be divided by 2, 3, 4 and 6
- 24 is the smallest number that can be divided by 2, 3, 4, 6, 8, 12
- 60 is the smallest number that can be divided by 2-6, 8, 10,...
- 360 is the smallest number that can be divided by all numbers between 2 and 10 except 7,...
etc..
So any unit using those bases weither it is a time, an angle or a number of eggs can easily be divided into 2, 3, 4 or 5 parts which is convenient 99% of the cases.
Operator: What can I do for you? Archangel: My friend... he... he has a cardiac arrest. I think he is dead. Operator: Calm down! Go back to your friend and check that he is dead. Archangel: Ok......... PAN...... Archangel: I confirm! He is dead now.
But seriously: Friends do not let friends write fortran.
I do not really agree with that. Fortran 90 and above is a nice language. The problem is people still using old and obsolete F77 features.
Of course, I would not recommand using Fortran 90 for anything else than numerical codes. If you have to manipulate multi-dimensionnal arrays, Fortran is the right language. This is where C/C++ clearly sucks.
Anarcobra description of what is happening is probably quite accurate (at least for some styles) but the problem is that he tries to give a complex interpretation to a simple behavior: What is actually happening in emacs is that everything is indented using spaces (of various numbers depending of the choosen style and context) and every sequence of 8 spaces (as controled by tab-width) is replaced by a TAB (unless indent-tabs-mode is nil).
If you wrongly believe that the indentation algorithm has rules to select spaces and tabs according to the current context then the behavior is likely to appear very strange. Most of the other editor I know also work using a similar approach except that their default tab width is smaller and their default indentation levels are choosen to match the tab width which gives the impression that everything is indented using TABs. Simply speaking, Emacs with a tab width of 2 or 4 will do exactly the same.
Emacs also allows you to add local configuration variable inside each file to customize its behavior.So if you do not want to change tab-width globally, just add the following to each C/C++ file indented using a tab-width of 4:
/* Local Variables: *//* tab-width: 4 *//* End: */
This works for almost all major modes using their respective comments
It seems to me that using TAB to indent is always a bad idea except in language where they are strictly needed.
There are actually 2 ways to indent using TAB:
(1) by giving each TAB a fixed width
(2) by jumping to the next alignment column (as in libreoffice, word)
The second method makes sense for regular text using proportionnal fonts but not for code.
The first method is the most common and the reason why codes idented that way often look bad in emacs is because it interprets TAB as 8 spaces instead of 4 or 6. This can easily be fixed by setting the variable tab-width to the proper value
Unless you really care saving a few bytes per line of codes, I recommend disabling TAB globally in emacs with (setq-default indent-tabs-mode nil)
Simply speaking, computing the TAN of 1.5707963267948966193 in double precision does not make sense. That's a typical floating point precision.
Now, if you really want to discuss the precision of TAN, you should use 0x1.921FB54442D18p+0 or any other value with an exact double precision representation. But even then, it does not really make sense to discuss the precision near special values such as PI/2 because the precision of your input data will be unrealiable around that number.
Any setuid program that would call a bash script directly or indirectly could also be vulnerable.
I predict that in the following days hackers will find several ways to cause local privileges escalations by executing system bash scripts with customized environment variables. That could be as simple as configuring a hidden WiFi network with a customized ESSID.
The doubling time looks like 30 to me (1000 at 110 and 2000 at 140) According to the given formula e^(0.022x+4.591) it is actually log(2)/0.022 = 31.5 e^(0.022*0+4.591) = 98 e^(0.022*31.5+4.591) = 197 e^(0.022*63+4.591) = 394 e^(0.022*94.5+4.591) = 788...
There is no such thing as nuclear cauterization except in movies and video games. A nuclear attack in a densely populated area would just destroy the medical infrastruture and would create thousands or millions of survivors most of them affected by radiations and so with a weakened immune system. The pandemic would spread very fast.
Humm... If the purpose of that function is to check that the interval fromIndex:toIndex is valid within an array on length arrayLen then there is another sensible way to implement that function.... without a bug:
This code does not throw ArrayIndexOutOfBoundsException if toIndex == arrayLen
The link to the Richard Stallman page is not against ebooks but about Amazon ebooks, or to keep it simple about DRM, proprietary formats and all other nice features introduced to "protect" users
There is nothing wrong with open ebook formats such as EPUB (XHTML+CSS+XML) as they remain DRM free.
Let's assume
- an average page is 10x10 inches (25x25 cm)
- a high scan resolution of 1200DPI
- 32bits per pixel (4bytes)
An average uncompressed page takes 10*10*1200*1200*4 = 576000000 = 0.57 gigabytes
A lossless compression can probably reduce the size by 2 but if they are not stupid they will make multiple backups so 1.2 gigabytes per page seems reasonable to me.
> Why didn't they chose 12 as a number of hours, and not 10? Or 8? But as it is, we have hours, minutes and seconds, and our whole physics and other sciences revolve around those units.
Use of bases 12, 24 and 60 originates from the Babylonian time. Those numbers have a high number of divisors (relative to their values). More specifically ... ... ..
- 12 is the smallest number that can be divided by 2, 3, 4 and 6
- 24 is the smallest number that can be divided by 2, 3, 4, 6, 8, 12
- 60 is the smallest number that can be divided by 2-6, 8, 10,
- 360 is the smallest number that can be divided by all numbers between 2 and 10 except 7,
etc
So any unit using those bases weither it is a time, an angle or a number of eggs can easily be divided into 2, 3, 4 or 5 parts which is convenient 99% of the cases.
This is a recording of Archangel calling 911:
Operator: What can I do for you? ... he ... he has a cardiac arrest. I think he is dead. ... ... ... PAN ... ...
Archangel: My friend
Operator: Calm down! Go back to your friend and check that he is dead.
Archangel: Ok
Archangel: I confirm! He is dead now.
But seriously: Friends do not let friends write fortran.
I do not really agree with that. Fortran 90 and above is a nice language. The problem is people still using old and obsolete F77 features.
Of course, I would not recommand using Fortran 90 for anything else than numerical codes. If you have to manipulate multi-dimensionnal arrays, Fortran is the right language. This is where C/C++ clearly sucks.
on Debian/Ubuntu that is pdflatex
Use Dr Who to teach science ... yeahhhh... what could go wrong?
And this one
* "You don't have to write your Fortan codes in UPPERCASE ONLY"
Anarcobra description of what is happening is probably quite accurate (at least for some styles) but the problem is that he tries to give a complex interpretation to a simple behavior: What is actually happening in emacs is that everything is indented using spaces (of various numbers depending of the choosen style and context) and every sequence of 8 spaces (as controled by tab-width) is replaced by a TAB (unless indent-tabs-mode is nil).
If you wrongly believe that the indentation algorithm has rules to select spaces and tabs according to the current context then the behavior is likely to appear very strange. Most of the other editor I know also work using a similar approach except that their default tab width is smaller and their default indentation levels are choosen to match the tab width which gives the impression that everything is indented using TABs. Simply speaking, Emacs with a tab width of 2 or 4 will do exactly the same.
Emacs also allows you to add local configuration variable inside each file to customize its behavior.So if you do not want to change tab-width globally, just add the following to each C/C++ file indented using a tab-width of 4:
This works for almost all major modes using their respective comments
PS: Slashdot insists for removing newline from the code above. More exemples are in https://www.gnu.org/software/e...
It seems to me that using TAB to indent is always a bad idea except in language where they are strictly needed.
There are actually 2 ways to indent using TAB:
(1) by giving each TAB a fixed width
(2) by jumping to the next alignment column (as in libreoffice, word)
The second method makes sense for regular text using proportionnal fonts but not for code.
The first method is the most common and the reason why codes idented that way often look bad in emacs is because it interprets TAB as 8 spaces instead of 4 or 6. This can easily be fixed by setting the variable tab-width to the proper value
Unless you really care saving a few bytes per line of codes, I recommend disabling TAB globally in emacs with
(setq-default indent-tabs-mode nil)
1.5707963267948966193 is rounded as 0x1.921FB54442D18p+0
Look what would happens with different roundings:
tan(0x1.921FB54442D17p+0) = + 0x1.9153D9443ED0Bp+51
tan(0x1.921FB54442D18p+0) = + 0x1.D02967C31CDB5p+53
tan(0x1.921FB54442D19p+0) = - 0x1.617A15494767Ap+52
Simply speaking, computing the TAN of 1.5707963267948966193 in double precision does not make sense.
That's a typical floating point precision.
Now, if you really want to discuss the precision of TAN, you should use 0x1.921FB54442D18p+0 or any other value with an exact double precision representation.
But even then, it does not really make sense to discuss the precision near special values such as PI/2 because the precision of your input data will be unrealiable around that number.
... found my favorite e-book: "'Alice In Wonderlands) ; DROP TABLE Books ; --.epub"
... also known as a dick.
This unit measure, like inches and feet, comes from a body part of a ancien dead king.
On my ubuntu laptop, gunzip and zcat are Bash script.
Any setuid program that would call a bash script directly or indirectly could also be vulnerable.
I predict that in the following days hackers will find several ways to cause local privileges escalations by executing system bash scripts with customized environment variables. That could be as simple as configuring a hidden WiFi network with a customized ESSID.
The doubling time looks like 30 to me (1000 at 110 and 2000 at 140) ...
According to the given formula e^(0.022x+4.591) it is actually log(2)/0.022 = 31.5
e^(0.022*0+4.591) = 98
e^(0.022*31.5+4.591) = 197
e^(0.022*63+4.591) = 394
e^(0.022*94.5+4.591) = 788
There is no such thing as nuclear cauterization except in movies and video games.
A nuclear attack in a densely populated area would just destroy the medical infrastruture and would create thousands or millions of survivors most of them affected by radiations and so with a weakened immune system. The pandemic would spread very fast.
... are Adam Savage and Jamie Hyneman in holiday in Nicaragua?
Godwin! I saw it first! What did I win?
Yvahk/Havk hfref pna hfr gur sbyybjvat pbzznaq gb qrpbqr/rapbqr ebg13
ge n-mN-M a-mn-zA-MN-Z
Humm... If the purpose of that function is to check that the interval fromIndex:toIndex is valid within an array on length arrayLen then there is another sensible way to implement that function.... without a bug:
This code does not throw ArrayIndexOutOfBoundsException if toIndex == arrayLen
Not a problem! I just patented a system of 3 laws preventing those chips to harm humans
... what is the estimated number of deaths caused by pollution in the USA alone? and worldwide?
The link to the Richard Stallman page is not against ebooks but about Amazon ebooks, or to keep it simple about DRM, proprietary formats and all other nice features introduced to "protect" users
There is nothing wrong with open ebook formats such as EPUB (XHTML+CSS+XML) as they remain DRM free.
... the end of Dr House?
Let's assume
- an average page is 10x10 inches (25x25 cm)
- a high scan resolution of 1200DPI
- 32bits per pixel (4bytes)
An average uncompressed page takes 10*10*1200*1200*4 = 576000000 = 0.57 gigabytes
A lossless compression can probably reduce the size by 2 but if they are not stupid they will make multiple backups so 1.2 gigabytes per page seems reasonable to me.