i want to create a code which compares each column of the two lists below and outputs the position of io and rk. Unfortunately my syntax knowlegde is very bad by now. So i just splitted the string and tried a few things out, non of them worked out. I was hoping for a hint. category_1 = [     "19_IP21_IW_z9_FW_uh_ze_Ef_io_FC_9j_MB_2c_GX_Ly",      "19_IP21_IW_z9_FW_uh_ze_Ef_io_FC_9j_MB_2H_GX_Ly",     "19_IP21_IW_z9_FW_uh_ze_Ef_io_FC_9j_MB_Ad_GX_Ly",     "19_IP21_IW_z9_FW_uh_ze_Ef_io_FC_9j_MB_Fd_GX_Ly",     "19_IP21_IW_z9_FW_uh_ze_Ef_io_FC_9j_MB_Is_GX_Ly",     "19_IP21_Tx_z9_2S_EK_AG_Cd_io_FC_9j_wI_nC_Yy_Ly",     "19_IP21_Tx_z9_2S_zc_hI_z0_io_FC_9j_3Y_9z_Yy_Ly",     "19_IP21_Tx_z9_2S_zc_hI_z0_io_FC_9j_3Y_nC_Yy_Ly"]  category_2 = [     "19_IP21_Tx_z9_TF_EK_AG_Cd_rK_FC_9j_wI_9z_Yy_Ly",      "19_IP21_Tx_z9_TF_EK_AG_Cd_rK_FC_9j_wI_Fd_Yy_Ly",     "19_IP21_Tx_z9_TF_EK_AG_z0_rK_FC_9j_3Y_2z_Yy_Ly"]                      for name in category_1:       s_name = name.split("_")     print(s_name)      print("##############################################")  for name in category_2:     s_name = name.split("_")     print(s_name)


Scalar Least Absolute Deviation (LAD) Analytical Minimization

Is it possible to minimize least absolute deviations (LAD) analytically?  Say given a sample $\{x_i\}_{i=1..n}$ find  $$\arg\min_\lambda{\sum_{i=1}^{n}{|x_i-\lambda|}}$$


SELinux prevents Nginx from reading file

I have nginx running on my CentOS 7 machine. Every day I run a cron job that generates new Diffie-Hellman parameters. They are saved in /etc/ssl/dh/dhparam.pem. But SELinux is preventing nginx from reading this file.  This is the line in the nginx error log:  nginx[3189]: nginx: [emerg] BIO_new_file("/etc/ssl/dh/dhparam.pem") failed (SSL: error:0200100D:system library:fopen:Permission denied:fopen('/etc/ssl/dh/dhparam.pem','r') error:2006D002:BIO routines:BIO_new_file:system lib)  This is the audit log:  type=AVC msg=audit(1473285202.181:334): avc:  denied  { open } for  pid=1393 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646309 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file type=AVC msg=audit(1473285832.647:743): avc:  denied  { open } for  pid=2958 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646309 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file type=AVC msg=audit(1473287010.821:803): avc:  denied  { open } for  pid=3083 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646316 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file type=AVC msg=audit(1473287142.871:826): avc:  denied  { open } for  pid=3118 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646309 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file type=AVC msg=audit(1473287172.480:843): avc:  denied  { open } for  pid=3134 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646309 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file type=AVC msg=audit(1473287681.994:866): avc:  denied  { open } for  pid=3189 comm="nginx" path="/etc/ssl/dh/dhparam.pem" dev="dm-1" ino=101646309 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:user_tmp_t:s0 tclass=file   I'm not very familiar with SELinux (I know I should learn that): How can I grant nginx access without disabeling SELinux (or setting it to permissive)?


We bought a chess set in which the rules state that pawn promotion occurs when the pawn moves to the light square in the upper left corner of the opponent's first row. So, this cannot occur when the pawn reaches any square in the last row?  All the other answers to pawn promotion do not address a specific square rule.


When using a VPN, would my ISP still be able to read my internet traffic?

If I'm using a VPN service such as , would my ISP still be able to read my internet traffic?


done=False  while not done:     for level in range(1,13):        Code...         while running:             Code.....              #10 - Win/Lose check              if healthvalue<=0:                 done=True                 running=0                 exitcode=0                 print "aaa"   I have got this game on python which when the health is lower than 0, it should quit the loop. However, even though I state it so that done=True in the if statement, the loop still does not quit although running does become 0. I also checked by printing "aaa", and it does print, but yet done does not equal True in order to quit the loop.  Please help! Does it have something to do with the for loop?


How do you split a stack snippet into multiple sections?

Usually when I write an answer I explain each section of my code separately and then add a link to a JSFiddle demo at the end. For example take a look at :  Now with the introduction of  I would like to replace my JSFiddle links with stack snippets. However it seems that you cannot split your stack snippets into multiple sections. It would be nice if this were possible. It would be even better if you could arrange the sections in any order. The order in which the snippets should be rearranged could be specified in the language comment. For example: <!-- language: lang-js snippet: 2 --> <!-- language: lang-js snippet: 1 --> <!-- language: lang-js snippet: 3 -->  Currently the only other way I can split my code into multiple sections and use stack snippets is to duplicate the code (and rearrange and merge the sections) into a stack snippet at the end of the answer, which is okay: I can say “Here is the code put together.” However this method has the disadvantage that if I change some code in my section then I need to make the same change in my stack snippet. It would be nice if I only needed to make the change in one place.


AUCTeX and TikZ does not work in emacs for me : plz help?

I've looked around for resolutions however, could not find any.  Indeed the one response that is pointed out, I already tried.  I did the following  sudo gedit .emacs   and embedded the code provided by  into that file.  Am I supposed to run another command after I include that into the .emacs file ?  So that emacs knows that it has been upgraded ?  I then also took other posts into consideration, such as , but it did not help me.  Am I supposed to simply download the files into the auctex/ folder ? and/or the preview sub-folder ?   The minimum working example that does not preview is   \documentclass{article} \usepackage{tikz} \begin{document} \section{test} \begin{tikzpicture}   \draw [fill=orange] (1,1) rectangle (2,2); \end{tikzpicture} \end{document}   I then try to preview it using the C-c C-p C-s command but the TikZ picture doesn't show.   I am a newbie by the way. Any advice is appreciated.  UPDATE: I now realized that I can click on the icon that appears before \begin{tikzpicture} to view the error which I hereby append.  gs -dOutputFile\=\(_region_.prv/tmp5466eRu/pr1-1.png\) -q -dDELAYSAFER  -dNOPAUSE -DNOPLATFONTS -dPrinted -dTextAlphaBits\=4 -dGraphicsAlphaBits\=4  -sDEVICE\=png16m -r127.763x127.523 GS>{<</PermitFileReading[(_region_.prv/tmp5466eRu/preview.ps)]>> setuserparams  .locksafe} stopped pop {DELAYSAFER{.setsafe}if}stopped pop/.preview-BP  currentpagedevice/BeginPage get dup null eq{pop{pop}bind}if  def<</BeginPage{currentpagedevice/PageSize get dup 0 get 1 ne exch 1 get 1 ne  or{.preview-BP }{pop}ifelse}bind/PageSize[1  1]>>setpagedevice/preview->do{[count 3 roll save]3 1 roll dup length 0 eq{pop}> {setpagedevice}{ifelse .runandhide}stopped{handleerror quit}if aload pop  restore}bind def [(_region_.prv/tmp5466eRu/preview.ps)(r)file]aload exch dup 0  setfileposition 25159()/SubFileDecode filter cvx .runandhide aload pop dup dup  25270 setfileposition 497()/SubFileDecode filter cvx<<>>preview-do Error: /undefined in pgfo Operand stack: Execution stack:    %interp_exit   .runexec2   --nostringval--   --nostringval--    --nostringval--   2   %stopped_push   --nostringval--   --nostringval--    %loop_continue   --nostringval--   --nostringval--   false   1    %stopped_push   .runexec2   --nostringval--   --nostringval--    --nostringval--   2   %stopped_push   --nostringval--   --nostringval--    false   1   %stopped_push   1148   --nostringval--   %end_runandhide    --nostringval-- Dictionary stack:    --dict:1169/1684(ro)(G)--   --dict:0/20(G)--   --dict:83/200(L)--    --dict:106/300(L)-- Current allocation mode is local Last OS error: 2 Preview-Ghostscript finished   UPDATE UPDATE: I also edited the .emacs file without the sudo command. I also included the following packages but it still does not work  \usepackage[active,float]{preview}  \PreviewEnvironment{tikzpicture}


Way for members to block specific community members from commenting/answering posts?

I've recently had one member in particular who wastes hours of my time asking/commenting about my posts without contributing anything productive towards answering them. I don't want to appear rude to other members (who obviously wouldn't be aware of the history), so I feel obligated to respond to each comment.   In addition, I've noticed that once this member starts participating I am significantly less likely to get input from other members (probably because they either assume that he's solving the problem, or because they get as big a headache as I do trying to read through the comments), and I'm therefore not getting questions answered if this member responds to them.  I don't believe that it would be appropriate and/or helpful to flag the comments  because there's nothing grossly wrong with a comment when viewed individually, and as far as I understand flags don't affect an individuals privileges.  Is there anything that I can currently do to limit and/or block this member from commenting/answering my posts, and if not, is this something that would be worthwhile considering in the future?


Am I correct that a block inside main() doesn't have separate scope?  For example, if I do the following, I will get compile error:  static int i = 1;  public static void main(String[] args) {    int i = 2;     {        int i = 3;     } }   Why is this?


How does the outer function "store" the arguments for the inner function?

I found this example in Mozilla developers page, but can't understand the concept.     function outside(x) {        function inside(y) {           return x + y;        }        return inside;     }     fn_inside = outside(3); //returns inside(y) -- from firebug     result = fn_inside(5); // returns 8      result1 = outside(3)(5); // returns 8   It seems like 3 is somewhat stored in the function 'inside' and during the second call adds it with 5 and returned 8.  And how does the second call to outside (outside(3)(5)) returned value (8) instead of the inner function (inside) unlike the first call?


Is it possible to run Junit tests parallelly?

Can Junit be multi threaded say multiple threads trying to run different Junit tests to complete faster assuming each TestCase is mutually independent .. I could not find any configuration as such .


Prove that $\int_E |f_n-f|\to0 \iff \lim\limits_{n\to\infty}\int_E|f_n|=\int_E|f|.$

I'm reading Real Analysis by Royden 4th Edition.  The entire problem statement is:  Let $\{f_n\}_{n=1}^\infty$ be a sequence of integrable functions on $E$ for which $f_n\to f$ pointwise a.e. on $E$ and $f$ is integrable over $E$. Show that $\int_E |f_n-f|\to0 \iff \lim\limits_{n\to\infty}\int_E|f_n|=\int_E|f|.$  My attempt at the proof is:  $(\Longrightarrow)$ Suppose $\int_E|f_n-f|\to0$ and let $\varepsilon>0$ be given. Then there exists an $N>0$ such that if $n\geq N$ then $|\int_E|f_n-f||<\varepsilon.$ Consider $$|\int_E|f_n|-\int_E|f||=|\int_E(|f_n|-|f|)|\leq|\int_E|f_n-f||<\varepsilon.$$ Thus, $\int_E|f_n|\to\int_E|f|.$   $(\Longleftarrow)$ Suppose now that $\int_E|f_n|\to\int_E|f|.$ Let $h_n=|f_n-f|$ and $g_n=|f_n|+|f|$. Then $h_n\to0$ pointwise a.e. on $E$ and $g_n\to2|f|$ pointwise a.e. on $E$. Moreover, since each $f_n$ and $f$ are integrable $\int_E g_n=\int_E|f_n|+|f|\to2\int_E|f|.$ Thus, by the General Lebesgue Dominated Convergence Theorem, $\int_E|f_n-f|\to\int_E0=0.$  I'm pretty sure I got this one down, but I was wondering if it was okay for $g_n$ to depend on $f$ or $f_n$ or does it need to be independent of them?  Thanks for any help or feedback!


When trying to update I get an error message   E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.    But when I try to run this command the screen goes completely black and nothing happens.  From what I can tell it is trying to install Linux headers when this happens.  This is a fresh install of less than a week old. At this time I can not install anything new or update anything. How do I solve this issue?  Log File:  12:50:16 systemd-journal: Journal stopped 12:50:16 kernel: Sending SIGTERM to remaining processes... 12:50:16 kernel: Syncing filesystems and block devices. 12:50:16 kernel: printk: systemd-shutdow: 78 output lines suppressed due to ratelimiting 12:50:16 systemd: Shutting down. 12:50:15 NetworkManager: <info>  [1565373015.4510] exiting (success) 12:50:15 systemd: Stopped Raise network interfaces. 12:50:15 NetworkManager: <info>  [1565373015.4124] caught SIGTERM, shutting down normally. 12:50:15 systemd: Stopping Network Manager... 12:50:15 pulseaudio: E: [alsa-sink-HDMI 1] alsa-sink.c: Error opening PCM device hdmi:0,1: No such file or directory 12:50:15 systemd: Stopped D-Bus User Message Bus. 12:50:15 systemd-logind: Removed session 2. 12:50:15 systemd: Stopping D-Bus User Message Bus... 12:50:15 gdm-x-session: (II) Server terminated successfully (0). Closing log file. 12:50:14 systemd: Stopped ACPI event daemon. 12:50:14 (sd-pam): pam_unix(systemd-user:session): session closed for user gdm 12:50:14 systemd: gdm.service: Succeeded. 12:50:14 gdm3: Child process -1517 was already dead. 12:50:14 systemd: Started Exit the Session. 12:50:14 gdm3: Child process -1517 was already dead. 12:50:14 systemd: systemd-exit.service: Succeeded. 12:50:14 gdm-x-session: (II) systemd-logind: releasing fd for 13:65 12:50:14 systemd: Stopped sandboxed app permission store. 12:50:14 systemd-logind: Removed session c2. 12:50:14 gdm-x-session: (II) systemd-logind: releasing fd for 13:64 12:50:14 systemd: Stopping User Manager for UID 123... 12:50:14 gdm-x-session: (II) Server terminated successfully (0). Closing log file. 12:50:13 gdm3: Freeing conversation 'gdm-launch-environment' with active job 12:50:13 systemd: Stopped Network Manager Wait Online. 12:50:13 dbus-daemon: [system] Activation via systemd failed for unit 'accounts-daemon.service': Refusing activation, D-Bus is shutting down. 12:50:13 systemd: Stopped target Network is Online. 12:50:13 gdm3: Tried to look up non-existent conversation gdm-launch-environment 12:50:13 gdm-x-session: (II) systemd-logind: releasing fd for 13:68 12:50:13 avahi-daemon: avahi-daemon 0.7 exiting. 12:50:13 dbus-daemon: [system] Activating via systemd: service name='org.freedesktop.Accounts' unit='accounts-daemon.service' requested by ':1.478' (uid=0 pid=3680 comm="gdm-session-worker [pam/gdm-launch-environment] " label="unconfined") 12:50:13 systemd: Stopped CUPS Scheduler. 12:50:13 gdm3: Failed to list cached users: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name :1.7 was not provided by any .service files 12:50:13 systemd: Stopped PackageKit Daemon. 12:50:13 udisksd: udisks daemon version 2.8.2 exiting 12:50:13 systemd: Stopped Accounts Service. 12:50:13 apport:    ...done. 12:50:13 systemd: Stopped LSB: Record successful boot for GRUB. 12:50:13 dbus-daemon: [session uid=1000 pid=3647] AppArmor D-Bus mediation is enabled 12:50:13 systemd: Stopping Authorization Manager... 12:50:13 avahi-daemon: Leaving mDNS multicast group on interface lo.IPv4 with address 127.0.0.1. 12:50:13 systemd: Stopped target Host and Network Name Lookups. 12:50:13 avahi-daemon: Leaving mDNS multicast group on interface enp7s0.IPv4 with address 192.58.0.150. 12:50:13 systemd-logind: Session c2 logged out. Waiting for processes to exit. 12:50:13 systemd: Stopping CUPS Scheduler... 12:50:13 avahi-daemon: Leaving mDNS multicast group on interface enp7s0.IPv6 with address fe80::fd7:6a47:d5ba:6c3c. 12:50:13 systemd-logind: Session 2 logged out. Waiting for processes to exit.


I have a lenovo z500 with dual boot Windows 8 and Ubuntu 13.04. Recently I deleted the Linux partition (from windows disk manager) but did not remove the boot loader.Now the next time I booted it gave the following error.   No such partition found  Grub rescue   I tried to make a super grub disk but when I insert it in the machine nothing happened it still gave the same response.  Please help.


I hope I am in the right place. I have a 2019 macbook pro, 13-inch, 2019, Two Thunderbolt 3 ports, 1.4 GHz Quad-Core Intel Core i5, 8 GB 2133 MHz LPDDR3, Intel Iris Plus Graphics 645 1536 MB I have been researching online the next step of optimizing my performance in Blender, but everything I'm finding is conflicting and outdated. Do I need an eGPU? What is the best option for a macbook with my specs?


I'm confused about how to hyphenate two locations in a single sentence. For instance:  "A New York and London-based agency focused on making brands heard."  or   "A New York- and London-based agency focused on making brands heard."  Which one is the right way to hyphenate?


Footenote in table appear only as alpha letters

I'm trying to add footnotes to a table with arabic numerals, but it comes up as alpha letters instead:  begin{minipage}{500pt}    \renewcommand{\thefootnote}{\arabic{footnote}} \begin{tabular}{rcccc} \\ \hline \noalign{\vskip 1mm}   \multicolumn{5}{c}{\ce{Fe(NO)3\cdot9H2O}} \\  Trials & $m_o$\footnote{\scriptsize Mass of capillary} & $m$\footnote{\scriptsize Mass of capillary and sample} & $L$\footnote{\scriptsize Length} & $R$\footnote{\scriptsize Magnetic balance reading of sample} \\ \hline 1 & \SI{0.1873}{g} & \SI{0.2345}{g} & \SI{3.56}{cm} & 414 \\ 2 & \SI{0.1914}{g} & \SI{0.2340}{g} & \SI{3.56}{cm} & 414 \\ 3 & \SI{0.1827}{g} & \SI{0.2180}{g} & \SI{3.56}{cm} & 414 \\ 4 & \SI{0.1881}{g} & \SI{0.2193}{g} & \SI{3.56}{cm} & 414 \\ \end{tabular} \end{minipage}   Thanks for the help!


Blender Python: Where do I get an Image with all the indices for the edges and faces of a cube?

I just need to know the index numbers of certain edges and faces in a cube in blender.  Is there anywhere a diagram of that? Or can this be shown in blender as e.g. the length of an edge.


Supposed you are using an Isolation Transformer with 115kV primary, should you worry about the capacitive current going through it? What would happen if you touch one of the output leads? Remember an isolation transformer secondary is independent from ground.  I always used isolation transformer when diagnosting circuits so I'd not get a shock or the equipment broken by having the path to ground.  To get better understanding. I'd like to know what would happen if the ground rods in North American utility pole were say stolen and at the same time your service panel ground rods didn't work because say the contacts got molds or disconnected and contact to ground completely lost . This would make the utility tansformer secondary floating, so your appliances enclosure could become live. What would happen if you touch the appliances metal enclosure like metallic washing machine body, would you get a shock? or be electrocuted theoretically? But how can you get shock when you were isolated from ground already.


how to display dates between two dates using mysql

Hi i try to display dates between two dates(i don't have any table ) using mysql. simply i have two dates 2013-10-01 and 2013-10-05 but i did't success   ;WITH cte AS ( SELECT CASE WHEN DATEPART(Day,@StartDate) = 1 THEN @StartDate              ELSE DATEADD(Month,DATEDIFF(Month,0,@StartDate)+1,0) END AS myDate UNION ALL SELECT DATEADD(Month,1,myDate) FROM cte WHERE DATEADD(Month,1,myDate) <=  @EndDate ) SELECT myDate FROM cte OPTION (MAXRECURSION 0)     i think this works on only sqlserver not in mysql  i want output like  2013-10-01 2013-10-02 2013-10-03 2013-10-04 2013-10-05


Let $f_n(x) = (1 + \cos x)^n$ ,$f_n:[0,1]\to\mathbb{R}$ and let $a_n =\displaystyle\int_0^{\frac{1}{2^n}} f_n(x)\,dx$. Calculate the sequence limit or prove that the limit does not exists.  I tried to compute the integral using riemann sum but I got stocked choosing random ci. Can some one help with this question please ?


Get object rotation (or any property) in a frame_change_pre handler while rendering

I'm using the frame_change_pre handler to get an object rotation and write it down on a text object. It works ferpectly in the playback, but not in render. I assume that's because while rendering the GUI is not updating.  So, how can I get such values in render time?


Segmentation fault - longest common prefix divide and conquer

I've just started learning about divide and conquer and I'm trying to write a program that displays the longest common prefix from a list of strings. #include <stdio.h> #include <string.h> #include <stdlib.h>  const char *lcpUtil(char str1[], char str2[]) {     char *result = malloc(sizeof(char) * 100);     result = "";     int n1 = strlen(str1), n2 = strlen(str2);          for(int i = 0, j = 0; i <= n1-1 && j <= n2-1; i++, j++)     {         if(str1[i] != str2[j])             break;         strncat(result, &str1[i], 1); // append the prefix to the result string     }           return (result); }  const char *lcp(char **str, int l, int r) {     char str1[100], str2[100];      if (l < r)     {         int m = (l + r)/2;                  strcpy(str1, lcp(str, l, r));         strcpy(str2, lcp(str, m+1, r));     }      return (lcpUtil(str1, str2)); }  int main(int argc, char **argv) {     char *arr[4] = {"apple", "application", "april", "apartment"}; // ap     int n = 4;     char prefix[100];      strcpy(prefix, lcp(arr, 0 , n-1));      if(strlen(prefix))     {         printf("The longest common prefix: %s\n", prefix);     }     else         printf("There is no common prefix");      return 0; }  Right now, I'm getting a segmentation and I'm not certain why.


print the name of a key in dictionary which has lowest value in python

I have a python dictionary:  dic={'a':'17','b':'9','c':'11'}   I want to find the lowest value in this dictionary and show the KEY name of that value  in the example above, I want the name : b


Proving $a\sin\theta+b\cos\theta=R\sin(\theta+\alpha)$, where $R=\sqrt{a^2+b^2}$ and $\tan\alpha=\frac ba$

The R-method: If $R = \sqrt{a^2 + b^2}$ $a \sinθ + b \cosθ$ $= R \sin(θ + α)$, where $\tan α = \frac ba$ $=R \cos(θ − α)$, where $\tan α = \frac ab$ Its proof provided  makes some assumptions that do not seem intuitive. Is there any alternative way to prove this?


I'm trying to have a bash script create a variable and have the variable persist in the terminal until the terminal closes (not permanently). I thought export was what I needed but it didn't work.  #!/bin/bash  export VARIABLE='this is a test'   Then run the script:  $ ./test.sh   Then in the same terminal:  $ echo "$VARIABLE"   But it produces a blank response.


How to insert a value into a list without it being a list inside a list

I am trying to create a blackjack game in python and I've come to a standstill. I need to use the sum function in order to check if the player has over 21 or not but when I use .append, it inserts the new value into the player's hand as such. You now have ['K', 8, [4]] Then when sum tries to add it all together, it can't grab the last value. I believe this is because it is in it's own set of brackets. (Which is a list in a list?) Any help would be greatly appreciated! Thank you!  import random deck = [2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 9,         9, 9, 9, 0, 0, 0, 0, "J", "J", "J", "J", "Q", "Q", "Q", "Q", "K", "K", "K", "K", "A", "A", "A", "A"] value = {"2": 2, "3": 3, "4": 4, "5": 5, "6": 6, "7": 7, "8": 8,           "9": 9, "0": 10, "J": 10, "Q": 10, "K": 10, "A": 1, "A": 11} random.shuffle(deck)  player = [deck.pop() for i in range(2)] dealer = [deck.pop() for i in range(2)]  print("You have", (player)) print("The dealer has", dealer)  def hit():     playing = True     while playing:         hit = input("Do you want to hit or stand ")          if hit == "hit":             player.append([deck.pop()for i in range(1)])             print("You now have" , player)             print("The dealer has", dealer)             if sum(player) > 21:                 print("You bust! The dealer wins and steals all your hopes and dreams!")                 playing = False           elif hit == "stand":             print("It is now the dealer's turn")             playing = False          else:             print("Please choose either ""Hit"" or ""stand")  hit()


When should I use convection when baking?

I think I understand what convection does, and (some) of the benefits, such as eliminating hot/cold spots, and being more efficient overall.  Does this mean that I should always take advantage of it?  If not, which circumstances are better for convection, and which are better for regular bake/broil?


How was Skynet created in the original timeline?

The Terminator movies leave us with a sort of "chicken or the egg" problem.  Let's review some key facts   In 2029, Skynet sends a T-800 back to kill Sarah Connor In 2029, John Connor sends Kyle Reese back to 1984 to protect Sarah Connor In 1984, it is heavily implied (though I don't recall any explicit confirmation) that Kyle Reese impregnates Sarah Connor who later gives birth to John Connor. In the final battle, the Terminator is destroyed but one of his processors and hand survive. In 1995, it is revealed that Cyberdyne recovered/acquired the remnants and Miles Dyson is on his way to creating the first version of Skynet.    So, in this scenario, we are led to believe we are in a time loop. John sends Kyle -> Kyle fathers John and inadvertently leaves technology responsible for Skynet -> John sends Kyle... round and round we go.  But much like the chicken or the egg, someone had to have created Skynet before the time loop actually started. Has this ever been addressed?  Corollary: Who was John's father in this original timeline?


Copy raw link found by Google search, not the one with extra redirect added

In Firefox, after searching for some keyword in Google and getting a list of results, I would like to copy the link address of a particular result. But I find that the link address is not the actual address, but some modification by Google to include some information about Google itself.   For example, search "regex Is it worth using Python re.compile" in Google, and the first result is "regex - Is it worth using Python's re.compile? - Stack Overflow" whose address is .   Right-clicking the result, and selecting "copy the location", I will get         But I wish to get just .  I remember Google search used to work in the same way as I wish, but now it has changed. I was wondering if I am missing something and how to do as I wish?


Calculating days of week given a week number

Given a week number, e.g. date -u +%W, how do you calculate the days in that week starting from Monday?  Example rfc-3339 output for week 40:  2008-10-06 2008-10-07 2008-10-08 2008-10-09 2008-10-10 2008-10-11 2008-10-12


How do I remove a Kwikset deadbolt with no screws on the inside plate?

My exterior door deadbolt has gotten stuck - it'll open with the lever but not the key. By spraying WD-40 inside the lock, I've been able to get it to work but it's very stiff. I'd like to remove the lock and inspect the inside, either to clean/lube it or replace it. But I can't figure out how to remove the lock; there's no obvious way to do this. (I'm used to seeing two screws on the inside of the deadbolt, usually under the lever arms when it's horizontal.)    How do I remove this? I can loosen the cover plate on the inside but it doesn't do anything other than rotate a few degrees.


How can I use two WiFi connections simultaneosly?

My Lenovo G50 laptop running Ubuntu has an inbuilt WiFi Adapter, and I also have a USB WiFi Adapter. When I plug in the USB adapter, I see both of the adapters in the Network settings, and they both seem to be able to connect to a router.   I wanted to know if it is possible for me to double my internet speed by connecting to 2 different WiFi APs at the same time, one with each adapter, or if maybe Ubuntu does that already automatically?   If I do have do do something to make this work, please do tell.


Unable to use less than or greater inside java script in xsl

I want to write the if condition by using greater than or less than symbol inside java script in xsl. I used like this '<' , but getting SyntaxError: missing ) after condition in the html.  Please share your suggestions.  <![CDATA[     if(1 < 1){         alert('yes');     }else{         alert('no');     }; ]]>


Execute api call from html button... How

I have a restful API on my node js server that pulls down into from my SQL DB. When I launch the js code it works and prints to my console log...   How do I get a button on my HTML page to execute this API call? So when the user clicks the button it launches that code and pulls down the info from the DB  here is my code in my js file that grabs the info from my DB  app.get('/getcount/apples', function (req, res) {         sql.connect(config, function (err) {             if (err) console.log(err);         var resultapples = new sql.Request();         result.query("SELECT count FROM table12 WHERE fruit = 'apples'", function (err, result, fields) {         var arrayLength = result.length;         for (var i = 0; i < arrayLength; i++) {         console.log(result[i]["count"]);         }; }); }); });   So how do i get that to launch / execute from my html page


I'm new to tikz-qtree, and can't find an automatic way to do something that qtree did very nicely.  With qtree, if you don't have a label for a single intermediate node, you get a straight line from the grandmother to the granddaughter.  With tikz-qtree, you get a "kink".  Compare the following:  With qtree:  \documentclass{article} \usepackage{qtree}  \begin{document}  \Tree [ Wiiiiiiiiiide [ nar- -row ] ]  \Tree [ nrw [ wiiiiiiiiiiiii- -iiiiiiiiiiiide ] ]  \end{document}   With tikz-qtree  \documentclass{article} \usepackage{tikz,tikz-qtree}  \begin{document}  \Tree [ Wiiiiiiiiiide [ nar- -row ] ]  \Tree [ nrw [ wiiiiiiiiiiiii- -iiiiiiiiiiiide ] ]  \end{document}   Is there any way to get the nice straight line in tikz-qtree, or do I have to adjust it manually?  Thanks in advance.


How to expand root partion in Ubuntu 19.10

I want to expand my root partition /dev/sda5 by adding unallocated space. Primary Partition is 30 GB and I want to add 20 GB more so that it can be 50 GB. I tried using gparted and live CD but doesn't work.


How to make headings (incl title) 12 pt font?

For a submission requirement, everything in my document has to be 12 pt. The submission structure is set up for Word submissions, as the organization largely works with scientists, but I need to use LaTeX for my specific submission. I've found other posts with commands to make section headers various sizes, but is there a package and command I can use to to specify the font size, as in 12-point, 11-point, etc, rather than the default LaTeX sizing parameters?


How to calculate the limit of $\frac{a_n}{n^2}$ for the sequence $a_{n+1}=a_n+\frac{2 a_{n-1}}{n+1}$?

Assume $\{a_n\}$is a sequence which  satisfies the following recursion formula: $$a_{n+1}=a_n+\frac{2a_{n-1}}{n+1}~(n\geqslant 1).$$ and $a_0=\pi,a_1=\pi^2 $. How to compute $\displaystyle\lim_{n\to \infty}\frac{a_n}{n^2}$?


If $m$ is a divisor of $k$ and $n$ is a divisor of $k$ and $m$ and $n$ prime to each other then $mn$ is divisor of $k$.  I tried but somehow I didnt manipulate.  As $m$ is divisor of $k$ then $k=mp$ for some $p$ and similarly $k=nq$ for some $q$ and as $gcd(m, n)=1$ there exist integer say $u$ and $v$ such that $mu+nv=1$  After that how I proceed?, Please help.


PHP: Replace umlauts with closest 7-bit ASCII equivalent in an UTF-8 string

What I want to do is to remove all accents and umlauts from a string, turning "lärm" into "larm" or "andré" into "andre". What I tried to do was to utf8_decode the string and then use strtr on it, but since my source file is saved as UTF-8 file, I can't enter the ISO-8859-15 characters for all umlauts - the editor inserts the UTF-8 characters.  Obviously a solution for this would be to have an include that's an ISO-8859-15 file, but there must be a better way than to have another required include?  echo strtr(utf8_decode($input),             'ŠŒŽšœžŸ¥µÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýÿ',            'SOZsozYYuAAAAAAACEEEEIIIIDNOOOOOOUUUUYsaaaaaaaceeeeiiiionoooooouuuuyy');   UPDATE: Maybe I was a bit inaccurate with what I try to do: I do not actually want to remove the umlauts, but to replace them with their closest "one character ASCII" equivalent.


I have the following problem:  Let $G$ be a finite group with transitive group action on a set $X$ (#$X > 1$). Prove: there exists an element $g \in G$ such that $gx \neq x$ for all $x \in X$.   It would be nice if anyone could help me getting started. Usually with these problems, I have trouble understanding what information I have given.  I know that transitive action is: $Gx = X$ for some $x \in X$. But how can I use this definition?  Regards.


Find and replacement of the numerical part of a particular string with increased value using terminal command

The inputfile is,  test00.dat test07.dat test03.dat aram22.dat test09.dat aram09.dat test13.dat   I need the output file as  test01.dat test08.dat test04.dat aram22.dat test10.dat aram09.dat test14.dat   i.e. the numerical string associated with test is increased by unity. I need a suitable terminal command-line to perform this operation.  Especially, I need to know the conversion mechanism of 'test09.dat' to 'test10.dat' change.


Change custom Node input through Python console

I have a custom node simulating a laser:    The node itself is pretty complex with rotations and whatnot, but it's attached to a Lamp object. In short what it does is illuminate a pixel if some conditions are met (mostly boolean checking with some algebra). It's based on . I have to create a demo to show the laser properties and how it can be tunned and changed. I would like to change the input values of this node (elevation,azimuth, turning around the laser beam axis and laser width/girth) from a python script.   How can I select and change the input values for this node and how can I set them depending on the frame number?


Apache: HSTS redirection on non-standard HTTP port causes SSL error

I've read a few answers on SF, and I'm no closer to a solution. My problem seems a little specific...  Customers were accessing a webserver on port 81. With the general trend towards HTTPS, the service was upgraded and installed on standard port 443. Crucially to my story, HSTS is enabled on the new HTTPS website.  On port 81, we put a simple Apache redirect:   ServerName example.com RewriteEngine on RewriteCond %{SERVER_NAME} =example.com RewriteRule ^ https://example.com/ [END,NE,R=permanent]   It worked. Accessing  will automatically redirected to   Thanks to HSTS, however, it works only once. I imagine that many users are accessing from links, bookmarks, cached Google searches... and are automatically being directed to . Even my browser's autocomplete still likes to suggest the :81 link, so I'm guessing I'm not the only one.  Their browsers, having a valid HSTS policy performs an internal upgrade to the insecure request which results in the browser sending a request to . This fails to load because of an SSL error - the port is not configured for SSL traffic.  I thus need a way to redirect  AND  to   I have seen Webmin, when accessed via  give a custom error message about the site being active on HTTPS which is generated by Webmin and not the browser. Even if I could get such a page to load and implement a <meta> refresh to the new URL, that would still please our users while the old URL plays itself out and is removed from links, caches and so on.


In season 2, episode 7 of The Mandalorian, Din is fighting some pirates and his blaster appears to either run out of ammo or jam up such that he can no longer use the blaster. Out-of-universe, I realize the explanation for this is the  as well as forcing our hero to physically engage with the Bad Guys. But I was wondering if there was an in-universe precedent for blasters suddenly failing to work (whether it be running out of ammo or jamming up).


curl -sS https://getcomposer.org/installer | sudo php -- --install- dir=/usr/local/bin --filename=composer    When I run the above command in terminal I got this this response:  Some settings on your machine make Composer unable to work properly. Make sure that you fix the issues listed below and run this script again:  The json extension is missing. Install it or recompile php without --disable-json  The phar extension is missing. Install it or recompile php without --disable-phar  The iconv OR mbstring extension is required and both are missing. Install either of them or recompile php without --disable-iconv


Unchecked or unsafe operations error in java compile?

I am completing a lab assignment for school and get this error when I compile. The program runs fine, bit would like to fix what is causing the error. The program code and the complete error is below. Thanks as always!  Error: Note: F:\Java\Lab 8\Lab8.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details.  Code:     import java.awt.*;    import java.awt.event.*;    import javax.swing.*;    import javax.swing.event.*;    import javax.swing.border.*;      public class Lab8 extends JFrame {        public Lab8()            {             // Create an array of Strings for age ranges            String[] ageRanges = {"Under 20", "20-29", "30-39", "40-49", "50-59", "60 and Above"};            JComboBox jcbo = new JComboBox(ageRanges);             // Create an array of String destinations            String[] destination = {"Mercury", "Venus", "Moon", "Mars", "Jupiter / Europa", "Saturn / Triton", "Pluto + Sharon"};            JList jlst = new JList();             // Declare radio buttons            JRadioButton jrbMonday, jrbTuesday, jrbWednesday, jrbThursday, jrbFriday;             // Create a textfield            JTextField jMsg = new JTextField(10);              // Create panel to hold label and textbox.            JPanel p1 = new JPanel();            p1.setLayout(new BorderLayout(5,0));            p1.add(new JLabel("Name: "), BorderLayout.WEST);            p1.add(new JTextField(20), BorderLayout.CENTER);            jMsg.setHorizontalAlignment(JTextField.LEFT);              // Create combobox panel.            JPanel p2 = new JPanel();            p2.setLayout(new GridLayout(2,0,5,5));            p2.add(p1, BorderLayout.NORTH);            p2.add(new JComboBox(ageRanges), BorderLayout.CENTER);                p2.setBorder(new TitledBorder("Passenger Name & Age Range"));              //Create listbox panel.            JPanel p3 = new JPanel();            p3.setLayout(new GridLayout(1, 0));            p3.add(new JList(destination));                p3.setBorder(new TitledBorder("Destinations"));              // Create a new panel to hold radio buttons.                JPanel r1 = new JPanel();            r1.setLayout(new GridLayout(3,2));            r1.add(jrbMonday = new JRadioButton("Monday"));            r1.add(jrbTuesday = new JRadioButton("Tuesday"));            r1.add(jrbWednesday = new JRadioButton("Wednesday"));            r1.add(jrbThursday = new JRadioButton("Thursday"));            r1.add(jrbFriday = new JRadioButton("Friday"));            r1.setBorder(new TitledBorder("Departure Days"));              // Create a radio button group to group five buttons            ButtonGroup group = new ButtonGroup();            group.add(jrbMonday);            group.add(jrbTuesday);            group.add(jrbWednesday);            group.add(jrbThursday);            group.add(jrbFriday);              // Create grid to hold contents            JPanel pMain = new JPanel();            pMain.setLayout(new BorderLayout(5,0));            add(r1, BorderLayout.CENTER);            add(p2, BorderLayout.NORTH);            add(p3, BorderLayout. EAST);  }   public static void main(String[] args)        {            Lab8 frame = new Lab8();            frame.pack();            frame.setTitle("Lab 8 Application");            frame.setLocationRelativeTo(null); // Center the frame            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);            frame.setSize(425, 275);            frame.setVisible(true);         } }


Singular noun after "or," or is that in dispute?

In the sentence "A junk vehicle is any vehicle, or parts of a vehicle, which meets at least three of the following criteria...," shouldn't "meet" be singular due to the preceding "or"? I've encountered some alternative treatment of situations like this so am confused. Thanks in advance.


How to get client IP address in Microsoft Edge browser using Javascript?

I have tried using webRTC to find client IP address using Javascript by following the below link and I am successful in Chrome and Firefox but it didn't work in Microsoft Edge.    How to get Client IP address in Microsoft Edge browser using Javascript?   Do we have any other alternate for WebRTC to get IP address in Edge browser?


How do I check if an integer is even or odd?

How can I check if a given number is even or odd in C?


What is the value for  $$\lim_{n\to\infty}\left(\frac{n+1}{n}\right)^{n}\ ?$$  According the answers given in the book, it should be $e$, but I can't solve it.  Can someone help me please?


Can someone tell me how to do operations with double?

double x= 2.2,y=2.13;  How can i do do operations like  x+y or x-y * x/y? For example x-y should be 0.07 but java gives me 0.07000000000000028


I tried writing a .img file to an existing partition (the partition that my computer boots  into). When I rebooted my computer it booted to "GRUB Rescue" and said "Unknown filesystem". I tried changing the BIOS and plugging in a USB but it didn't work. This is my main computer and I really need help. I screwed up big time.


What is the purpose of invitations on Stack Overflow Careers?

I have received five invitations on Stack Overflow Careers.   What are they?  Whom should I send them to?  What is the purpose of these invitations?


How to switch off "natural" sort order in Finder and enable pure alphabetical sort order?

I have a set of pictures named as hex representation of UUIDs. I want to see them ordered alphabetically as strings, but regardless what I try, the app shows me it differently:    I have these settings about grouping:   and sorting:   I think I figured out the order it represents. It looks like it tries to cut the longest string of decimal digits from the beginning of the name, interprets it as a number, and orders by this number. Albeit it can be convenient in some cases, it is not desired for me.  Is it possible to switch off this feature in Finder and obtain normal alphabetical sort order?  EDIT:  shines a light on the sorting algorithm but does not suggest how to switch it to normal string sorting.


How much dried herb to use when substituting for fresh herbs?

When replacing a fresh or leaf herb in a recipe with the dried or powdered kind, what is the ratio I should normally use for the substitution?  E.g. if the recipe calls for 2 teaspoons finely chopped rosemary, how much dried rosemary should I use?


Which method or component is best to regulate 42 to 3.3 V?

I am using a 36 V battey pack (10s 2.5 A each cell 3.6V.) Its maximum voltage is 42 V. I am using a STM32 microcontroller whose input is 3.3 V.  I am designing a PCB in which the power supply is drawn from the battery pack (42 V.) I would like to power the STM32 microcontroller from the battery pack power supply.  I would like to regulate 42 to 3.3 V so that I can power my STM32 microcontroller.   Which method is best to convert it either using regulator or buck converter based on the pcb designing?  Battery Specification: 10s1p   Battery pack nominal voltage: 36 V Battery pack maximum voltage: 42 V Battery pack current: 2500 mAh   Microcontroller specfication: STM32F401RCT6   Supply voltage: 3.3 to 3.6 V Supply current: 100 to 160 mA     Which method or component is best to regulate 42 V so that I can power my microcontroller with 3.3 V?


Link multiple value from table to point shapefile

In QGis 2.18 is there a way to link (like join) a table with multiple value for each ID CODE with a Point shapefile with only 1 point for each ID CODE?? (picture in annex)  It would be fine also a temporary link in my machine memory to keep light the shapefile!


It displays as "yesterday" but today is February 20 and question's date is February 18.


Should I backup my data partition before installing Ubuntu?

I have my HDD with two partitions (C:\ with W7 on it and D:\ with all my data). I really want to leave W7 behind and get my laptop only running Ubuntu :). When I run the installation CD, ¿will it delete my D:\ partition as well? Or can I install Ubuntu just fine without backing up my D:\ partition? I appreciate a lot your help.


My Girlfriend and I have been forming an alliance as soon as possible when playing against AI... when we get to the end though, all other races wiped out we were hoping to have a shared victory.  In the end she gave me most of her planets and then the game gave me the victory, but if we had split the galaxy basically in half do we REALLY have to fight each other once there are no other contenders?


KOMA-Script: How to left-align table/figure numbers in LoF/LoT

I use KOMA-Script's scrartcl and the lists of tables and figures show a strange default behaviour: the figure/table numbers are either indented to the right or are all right-aligned with a large reserved width. Either way, as it is I find it ugly and don't understand the reasoning behind it. The table of contents just above is perfectly left-aligned by default.  How could I change the numbers to be left aligned at the left margin, as my second screenshot shows? I couldn't figure it out from the KOMA-Script manual.  \documentclass{scrartcl}  \begin{document}  \tableofcontents  \listoffigures  \listoftables  \section{Section} \subsection{SubSection} \begin{figure}\caption{Testfigure}\end{figure} \begin{table}\caption{Testtable}\end{table} \end{document}   What this produces:     What I want:


How to block running two instances of the same program?

I need to make sure that user can run only one instance of my program at a time. Which means, that I have to check programatically, whether the same program is already running, and quit in such case.  The first thing that came to my mind was to create a file somewhere, when the program starts. Then, each other instance of the program would check for this file and exit if it found it. The trouble is, that the program must always exit gracefully and be able to delete the file it created, for this to work. In case of, say, power outage, the lock file remains in place and the program can't be started again.  To solve this, I decided to store the first program's process ID into the lock file and when another instance starts, it checks if the PID from the file is attached to some running process. If the file doesn't exist, is empty, or the PID doesn't correspond to any existing process, the program continues to run and writes its own PID to the file.  This seems to work quite fine - even after an unexpected shutdown, the chance that the (now obsolete) process ID will be associated with some other program, seems to be quite low.  But it still doesn't feel right (there is a chance of getting locked by some unrelated process) and working with process IDs seems to go beyond the standard C++ and probably isn't very portable either.  So, is there another (more clean and secure) way of doing this? Ideally one that would work with the ISO 98 C++ standard and on Windows and *nix alike. If it cannot be done platform-independently, Linux/Unix is a priority for me.


How to disable Low disk space for ReadyBoost dedicated drives on Windows 8.1?

I've enabled a disk partition of around 8 GB to be dedicated for .    Windows keep warning me about that disk running out of space (Low Disk Space).    How do I turn off that warning for THAT disk and ONLY that disk.  I DO want that warning, I do not want it for that disk I specifically instructed windows to completely fill.  I find it absurd that a Windows feature meant to completely fill a disk cause an annoying warning that you can't disable.


Euclidean Algorithm for GCD of polynomials

I am struggling to use the Euclidean algorithm for polynomials.  Given something like $$GCD(x^5+1, x^3+1)$$  I can easily use it as follows:   $$x^5+1 = x^2(x^3+1) -x^2 +1 \\ x^3+1 = -x(-x^2+1) + x +1 \\ -x^2+1 = (x+1)(-x+1)$$  GCD = x+1  But for something like $$GCD(2x^2+6x+3, 2x+1)$$   I cannot figure out how to do it using the same method. I start like this:  $$2x^2+6x+3 = x(2x+1) + 5x+3\\ 2x+1 = \frac{2}{5}(5x+3) - \frac{1}{5}\\$$  and I am not sure how to continue. Any help would be appreciated, sorry for my poor attempt at using LaTeX.


How can I access a linux box at home in my browser at work?

I want to be able to use taskwarrior at work.  But the computers at work don't allow me to install anything, they all run Win XP, and IE...  So, I would like to somehow SSH to a linux box at home, and do it through a browser.  I should mention that I'd be working with a dynamic IP.  Is this possible? If so, what is the simplest way to do this?


In answers to  I learned that if a contact is set up such that they have received iMessages from me, there still may be a way to force a new message I'm composing to go via SMS. I might want to do this if I suspect they are not connected to the internet but I need them to receive the current message quickly.  Question: How can I ensure or force a message I'm composing to go via SMS on my iPhone 6 in iOS 12?    Comments from 2016 (but no answers) to  seem to say this can't be done, but that was three years ago.  points to answers about how to modify the receiving phone's situation. Here I'm asking about forcing SMS on a single, current message on the sender's phone.


"This sentence is true". Is there a word for this class of statement?

Is there a term that means "A self referential statement which is true if (and because) it is true and false if (and because) it is false"? "This sentence is a lie" is a paradox in the sense of "paradox(noun) A self-contradictory statement, which can only be true if it is false, and vice versa." (Source: .) I'm looking for the opposite of that. I found the following on :  So we have reached the extraordinary result that the statement is always consistent, regardless of whether or not it is true!  Which notes that it is interesting, but doesn't give a name.


switch statement not working maybe misunderstanding

This should be easy but maybe im confusing how switch statements work. I have a data attribute associated with a list item. When you click the list item I pass the data attribute number to the switch which should run the function if the data attribute and the switch are equal. Isn't this how it works? Here the numbers should match up yet im getting the default every-time. However if i hard code the correct number it functions. Why is this? Thanks Stack,  HTML:

First Step

Slider

Social Hub

The Spirit

Elephant People

Elephant Room

Features

Spirit Award

Logout

   Javascript:      $('.nav_li').click(function(){       var $listItem = $(this);       var $point = $('.red_pointer');       var $rePoint = $listItem.attr('data-pointer-slide');         console.log($rePoint);     switch ($rePoint) {         case 10:             $point.animate({                top: '10%'             },1000);             break;         case 21:             $point.animate({                 top: '21%'             }, 1000);             break;         case 32:             $point.animate({                 top: '32%'             }, 1000);             break;         case 44:             $point.animate({                 top: '44%'             }, 1000);             break;         case 55:             $point.animate({                 top: '55%'             }, 1000);             break;         case 65:             $point.animate({                 top: '65%'             }, 1000);             break;         case 76:             $point.animate({                 top: '76%'             }, 1000);             break;         default:             console.log($rePoint);     } });


What is the difference between exit and return?

What is difference between return and exit statement in C programming when called from anywhere in a C program?


How to explain the motion of these pendulums?

Got very interested recently in a  video I saw running thru my feed:    Well, I got very intrigued about the physics of it and wanted to know your opinion about my guesses and how to proceed regarding them. I think that basically this mad motion is due to the fact that there's some ratio between the length of these pendulums. I spent a little time thinking and before solving the movement equations thought that maybe I couldn't use the approximation for small angles for that and MAYBE the initial motion would be related to a trasient term (indicating time interval which the system is oscillating for angles greater then 5 degrees) and then go to these repetitive patterns, for smaller angles in which the system is pretty much conservative). I thought about solving this numerically in Mathematica, plotting multiple pendulums with different lengths.


How to rename profile directory in windows 7?

I have renamed the account of a user in windows 7. How can I rename the profile directory to match the new user name?


Define a topology on the set of integers

Define a topology in the set of integers as follows: We declare that a set $U\subseteq \mathbb{Z}$ is open if for every $a \in U$ there exists an integer m such that $a + m\mathbb{Z} \subseteq U$. Prove that this notion of “open” indeed defines a topology on $\mathbb{Z}$. I was able to show that the empty set, the set $\mathbb{Z}$, and the union of collection of sets in the topology are in the topology. I am having trouble proving the finite intersection part. I start with let U and V be in the topology and $a \in U \bigcap V$. Then for $a \in U$ there exists some m such that $a + m\mathbb{Z} \subseteq U$ and same for V with a different m. And this is where I get stuck. I know i need to define my m's for U and V differently but I'm not sure what to do.


How do I calculate the affects of alcohol on someone that's been drinking as far as combat, using skills, and just the aftermath of a hangover?


Can I stop headnotes in one chapter of my thesis or edit it?

I am using my university thesis style and my main file code is shown below:  \documentclass[twoside]{ecsthesis}   \begin{document} \frontmatter  \title      {} \authors    {} \maketitle \begin{abstract} \end{abstract} \tableofcontents \listoffigures \listoftables \newpage \chapter*{Abbreviation} \addcontentsline{toc}{chapter}{Abbreviation} \input{Abbreviation} \newpage \chapter*{Nomenclature} \addcontentsline{toc}{chapter}{Nomenclature} \input{Nomenclature} \newpage \authorshipdeclaration{} \newpage \acknowledgements{Thanks to no one.} \mainmatter \include{Introduction} \appendix \include{AppendixI} \include{AppendixII} \backmatter \bibliography{references} \bibliographystyle{ieeetr} \end{document}   My problem is: The headnote of Abbreviation and Nomenclature chapters are 'list of tables' !!!!!!!!!!!!!!!  How can I fix this problem please ?


Is there a label that describes a person with whom I am sharing something

If I shared something with someone and you wanted to describe me in that context using only one word, you might call me the "sharer" or "owner".  What word could the person I'm sharing with be called?  Is he or she simply the "recipient" or is there a better word?  I am looking for a word that fit well as a Java class property name (don't let that discourage you from answering if you're not a software person).  For the software minded, I am writing a web app that uses Dashboards as the primary UI.  A user can have multiple dashboards and can share them with other users.  public class Dashboard {     ...     private String owner; // username of this dashboard's owner      ... // rest of the class }  public class DashboardShare {     private List<String> sharedWith; // <== I want to rename this property     private Dashboard dashboard;      ... // rest of the class }   Thanks in advance!  David


When you accept an answer on one of your questions, you get 2 reputation for it. The achievements dropdown tells you with a shiny green +2 on the topbar, and shows this:    Why did I get +2 for it again?  It would be better if the message told you it was because you accepted an answer, right there in the dropdown, without the need to go into your profile to see more details.


Show that any cyclic group of even order has exactly one element of order $2$   Attempt:  Let $G$ be a finite group of even order.  Assuming a set $A=\lbrace g \in G \vert g \neq g^{-1} \rbrace$, I can show that  $A\cup\{e\}$ has odd number of elements as $A$ has even number of elements. So $G$ has at least one element $a$ such that $a$ does not in $A$, ie $a=a^{-1}$ ie $a^2=e$. That is $G$ has atleast one element of order $2$. "More specifically, $G$ has odd number of elements of order $2$ --- ???"  But how to show that exactly one such element if $G$ be cyclic.     NB: Please don't use isomorphic properties.


Can I bring a painted Cow skull to the US with me via plane?

I bought this traditionally painted cow skull, a typical decoration item for the day of the dead. Since its bone (completely clean though) can I bring it with me on a plane as carry-on or special luggage, without having to declare it or having it confiscated?    []


Create Mac OS virtual machine on my Mac OS Catalina

What I want to do is create a Catalina OS () on my MacBook. I can't find anywhere how to do it. I figured that having a Mac, it would be easier to download the ISO file and then create the virtual machine. But still, I managed to download an ISO, but it is becoming impossible to create the virtual machine. When I load the ISO, the message I get is this:  What I have seen is that to create the virtual machine of Mac OS, in Windows or in Linux, it requires writing a series of commands in the CMD or Terminal respectively. Maybe that's it but I don't know.


What is the difference between tabular, tabular* and tabularx environments?

There have been quite a few hit on Google, including one in Tex SE, but none of those made a complete sense to me. Please don't write something like:     tabular* adjusts the space between text of adjacent columns to get a   given table width, tabularx leaves this intercolumn space fixed,   instead adjusts the text width within the "X" columns for same   purpose.   Can anyone provide an MWE that makes sense? Code speaks better than words.


Subtract two dates and get the result in years, months and days

I wrote the code below that will give me the difference between two dates and the result will be in years, months and days.  for me it's good code but the problem is with months coz It's fixed to 30 days  So if I subtract (1 feb 2014) - (1 jan 2014) It should be one month But with my code it will be 1 month 1 day  import java.util.*;  public class Main { public static void main(String[] args) {     int y_d = 365;     int m_d = 30;       Scanner scn = new Scanner(System.in);      System.out.println("Enter your first date: ");      System.out.print("Day   : ");     int day1 = scn.nextInt();      System.out.print("Month : ");     int month1 = scn.nextInt();      System.out.print("Year  : ");     int year1 = scn.nextInt();      Calendar cal1 = Calendar.getInstance();     cal1.set(year1,month1-1,day1);      System.out.println();     System.out.println("Enter your second date: ");      System.out.print("Day   : ");     int day2 = scn.nextInt();      System.out.print("Month : ");     int month2 = scn.nextInt();      System.out.print("Year  : ");     int year2 = scn.nextInt();      Calendar cal2 = Calendar.getInstance();     cal2.set(year2,month2-1,day2);      long milis1 = cal1.getTimeInMillis();     long milis2 = cal2.getTimeInMillis();      long day = milis2 - milis1;      long days = day / (24*60*60*1000);      System.out.println();     System.out.println("The difference : " + days + " days");      long y_r = (days % y_d);     long m_r = (y_r % m_d);      System.out.println("The result is approximatly");     System.out.println(days/y_d + " year(s)");     System.out.println(y_r/m_d + " month(s)");     System.out.println(m_r + " day(s)"); } }   Could I resolve this problem without using joda time???


How to make terminal autocomplete when there are several files/directory?

If I have several directories, like:  afoo abar   sometimes my terminal will refuse autocomplete when I press tab (e.g. "cd a" then tab), and print the list of directories instead. Sometimes it even throws a noisy, annoying sound. Any idea how to make it autocomplete in cases like this? E.g it can show abar first, and then afoo if I press tab again. I saw this is the case in windows, or some applciation in Ubuntu


In many episodes of Star Trek: TNG, people on a planet (or somewhere away from the Enterprise) transport back to their ship by someone tapping his/her communicator and saying "3 to beam up" or similar.  Then, the 3 people intended by that person almost immediately begin beam-out.  How does this work?  It often happens that the "N" people intended for transport are a subset of all the people available.  I thought perhaps it has to do with the stances of those N people, but that seems unlikely.  It also occurred to me that the computer could sense the thoughts of the person to figure out which people he/she means, but this is even more far-fetched, and has never been supported by any technobabble on the show.  There was one time someone says something like "2 people and one piece of equipment to beam up" (I don't remember which episode).  That made somewhat more sense, as the transporter chief could probably see via targeting scanners exactly which thing was the "piece of equipment" but it still leaves the question of which people to beam up fuzzy.  Anyone have other ideas?  This has always bugged me much more than other seeming weirdnesses on TNG, which I am usually able to come up with headcanon theories for.


What is the command for renaming file extensions from uppercase to lowercase?  Example:  hello.JPG hi.JPG   to:  hello.jpg hi.jpg


When do I get a "bonus" for catching a Pokemon?

Sometimes I get a bonus when catching a Pokemon. When does this happen? It happened already multiple times to me.  (I don't mean curveball, great or excellent bonus here. I mean the undefined "bonus" visible in the screenshot)


If $a_n >0$ for all $n\geq1$, show that the series  $$\sum_{n=1}^{\infty} \frac{a_n}{(1+a_1)(1+a_2)...(1+a_n)}$$  converges.  Can someone check if my solution is correct:  $$\sum_{n=1}^{M}\frac{a_n}{(1+a_1)(1+a_2)...(1+a_n)} = 1-\frac{1}{(1+a_1)(1+a_2)...(1+a_M)} < 1 $$  Since the partial sum of the series is bounded, the series is convergent.


Can a lens exist with an f-stop of less than 1?

As I understand it, the F-number of a lens is equal to the aperture diameter divided by the focal length. So f/1 would mean that the aperture is as wide as the lens is long.  Question: Is it physically possible for the aperture to somehow be wider than that? For example, something like an f/0.5 lens?  I gather that F-number is already the number one cause of expensive lenses, so even if such a lens is physically possible, it's likely to be far to expensive to actually buy. (To say nothing about whether it's even useful in the first place.) I'm just curious about the physics of the matter.


What is the difference between And and AndAlso in VB.NET?

In VB.NET, what is the difference between And and AndAlso? Which should I use?


How to erase ALL metadata associated with an image?

I'm looking for a way to get rid of ALL metadata associated with an image. What should I do?


Differentiation of $\sin(x^\circ)$  Can we say its derivative is $\cos x^\circ$? I read somewhere that in differentiation and integration, we assume $x$ should be in radians. But why so?


Finite Abelian group with the given property

Let $G$ be a finite Abelian group such that it contains a subgroup $H_0 \neq (e)$ which lies in every subgroup $H \neq (e)$. Prove that $G$ must be cyclic. What can you say about order of $G$ ?   I have examples to illustrate this result, but i can no idea about the general proof.  Here's my examples:  1) Take $G=\Bbb{Z}_8$ and $H_0=\{0,4\}$. Clearly $H_0$ lies every other subgroups $(\neq(e))$, namely lies in $\{0,2,4,6\}$ and lies in $\Bbb{Z}_8$   Here, $o(G)=8=2^3$  Edit:  2) Similarly, take $G=\Bbb{Z}_{16}$ and $H_0=\{0,8\}$. Clearly $H_0$ lies every other subgroups $(\neq(e))$, namely lies in $\{0,4,8,12\}$, $\{0,2,4,6,8,10,12,14\}$ and lies in $\Bbb{Z}_{16}$   Here, $o(G)=16=2^4$  3) Likewise, $G=\Bbb{Z}_{4}$ and $H_0=\{0,2\}$. Clearly $H_0$ lies every other subgroups $(\neq(e))$, namely lies in  $\Bbb{Z}_{4}$   Here, $o(G)=4=2^2$  From this examples, can i conclude $o(G)=p^n$, for a prime $p$ ?  Because, if $o(G)=p^n$, then there are unique subgroups of order $1,p,p^2,p^3,..,p^{n-1}$ and in this case we take $H_0$ as a subgroup of order $p$, then it is immediately lies in other subgroups.  Is this correct ? What is the general proof?


What is the best practices in naming methods in php?

What is the best way to know what should your method name be when developing a web app? I know this is an easy question, but seriously what considerations and practices should I be doing in order to derive the best names possible for my methods?


How to block all website on the basis of top level domain name in ubuntu 14 . For example I want to block all website on my system ending with ".info" or ".org " or " ".cn " .


Dual boot (Win 7 & Ubuntu 13.10 clock problem

I'm a "newbie" to Ubuntu, but I've been wrestling with this problem for several hours and don't seem to be able to solve it: When I set the time in Windows (Indianapolis, Eastern U.S. time zone) and then re-boot to Ubuntu, the computer time goes to Hawaiian time. When the time is set in Ubuntu, and the computer is rebooted to Windows the time is advanced by 5 hours.  I've set the time in the BIOS, and it seems to make no difference. I've tried setting the time from "automatic" to "manual", all with the same result. Not a big problem, but it shows some underlying glitch. Could anyone explain?


Shooting many bullets toward the mouse position

I try to shoot a bullet toward the mouse position by this code.  float deltaX = mousePosition.x - (aircraft.getPosition().x + aircraft.getLocalBounds().width / 2); float deltaY = mousePosition.y - (aircraft.getPosition().y + aircraft.getLocalBounds().height / 2); float angleRadian = (float)(std::atan2(deltaY, deltaX)); float angleDegree = (float)(angleRadian * 180 / PI);   It works fine with one bullet but when I add another one bullet to shoot together I use this code to specify start shooting point of each bullets.  sf::Vector2f offset1(aircraft.getPosition()); offset1.x += -10;//start shooting point first bullet.  sf::Vector2f offset2(aircraft.getPosition()); offset2.x += 10;//start shooting point second bullet.   this is a picture of this problem.   When I rotate aircraft to picture 2 the bullets are not the same as the first picture.  How can I solve this problem?


Bash script to automaticly change a given user's password

So, I know that the passwd command allows me to change my own password, and if run with sudo, allows me to change anyone's password, but what if I want a script to do it?  I have a script that grabs a username from list.txt and attempts to change their password.  I cant figure out how to have it automaticly set that password without me typing it in each time. I've tried:  username=john  password=12345  echo $password | passwd $username  echo 12345 | passwd $username  but I always get the error  Enter new UNIX password: Retype new UNIX password: passwd: Authentication token manipulation error   not sure what I'm doing wrong here, but i cant seem to find anyone with the same issue.


Why most of deb files I am trying to install are not supported by Ubuntu Software?

I tried to install Dropbox, now I am trying to install Sublime Edit Why deb files don't install itself??? I want the latest build and not some outdated version from Software Center that is few years old and uploaded by some anonymous user


How to unzip and dd a disk image to an SD Card with a single command?

I am under the following restrictions:   I have a 1.0 GB .zip file on my computer which contains one file, a disk image of raspbian. When uncompressed, this file is 3.2 GB large and named 2015-11-21-raspbian-jessie.img. After having downloaded the zip file, I have just under 1.0 GB of storage space on my computer, not enough space to extract the image to my computer. This file needs to be uncompressed and written to an SD card using plain old dd.   Is it possible for me to write the image to the SD card under these restrictions?  I know it's possible to pipe data through tar and then pipe that data elsewhere, however, will this still work for the zip file format, or does the entire archive need to be uncompressed before any files are accessible?


W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:2 and /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:3 W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:2 and /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:4 W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/noobslab-ubuntu-apps-dependencies-xenial.list:2 and /etc/apt/sources.list.d/noobslab-ubuntu-apps-dependencies-xenial.list:3 W: GPG error: http://extras.ubuntu.com/ubuntu precise Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 16126D3A3E5C1192 W: The repository 'http://extras.ubuntu.com/ubuntu precise Release' is not signed. N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use. N: See apt-secure(8) manpage for repository creation and user configuration details. W: http://archive.canonical.com/ubuntu/dists/precise/Release.gpg: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1) W: http://us.archive.ubuntu.com/ubuntu/dists/precise-security/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1) W: http://us.archive.ubuntu.com/ubuntu/dists/precise-updates/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1) W: http://us.archive.ubuntu.com/ubuntu/dists/precise-backports/InRelease: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1) W: http://us.archive.ubuntu.com/ubuntu/dists/precise/Release.gpg: Signature by key 630239CC130E1A7FD81A27B140976EAF437D05B5 uses weak digest algorithm (SHA1) W: The repository 'http://ppa.launchpad.net/webupd8team/jupiter/ubuntu oneiric Release' does not have a Release file. N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use. N: See apt-secure(8) manpage for repository creation and user configuration details. W: The repository 'http://ppa.launchpad.net/folke-schwinning/personal/ubuntu xenial Release' does not have a Release file. N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use. N: See apt-secure(8) manpage for repository creation and user configuration details. W: The repository 'http://ppa.launchpad.net/noobslab/apps-dependencies/ubuntu xenial Release' does not have a Release file. N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use. N: See apt-secure(8) manpage for repository creation and user configuration details. E: Failed to fetch http://ppa.launchpad.net/webupd8team/jupiter/ubuntu/dists/oneiric/main/source/Sources  404  Not Found E: Failed to fetch http://ppa.launchpad.net/folke-schwinning/personal/ubuntu/dists/xenial/main/source/Sources  404  Not Found E: Failed to fetch http://ppa.launchpad.net/noobslab/apps-dependencies    /ubuntu/dists/xenial/main/source/Sources  404  Not Found E: Some index files failed to download. They have been ignored, or old ones used instead. W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:2 and /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:3 W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:2 and /etc/apt/sources.list.d/moka-ubuntu-daily-xenial.list:4 W: Target Sources (main/source/Sources) is configured multiple times in /etc/apt/sources.list.d/noobslab-ubuntu-apps-dependencies-xenial.list:2 and /etc/apt/sources.list.d/noobslab-ubuntu-apps-dependencies-xenial.list:3   I tried solution from  link But not getting solution  I tried to install GRASS GIS, OSGeo, etc


How do I fix this "identifier is not declared in the current scope" error?

I got this identifier inputevenmousebutton is not declared in the current scope; should I use another identifier?  func _ready():     position = get_viewport_rect().size / 2     direction.x = rand_range(-1, 1)     direction.y = rand_range(-1, 1)     direction = direction.normalized()     width = get_viewport_rect().size.x     height = get_viewport_rect().size.y  func _process(delta):     position += direction * speed * delta     if position.x < 0 or position.x > width:         direction.x = -direction.x     if position.y < 0 or position.y > height:         direction.y = -direction.y  func _on_UFO_input_event( viewport, event, shape_idx ):     if event is InputEvenMouseButton and event.button_index ==          BUTTON_LEFT and event.pressed:         direction.x = rand_range(-1, 1)         direction.y = rand_range(-1, 1)           direction = direction.normalized()         position.x = rand_range(1, width -1)         position.y = rand_range(1, height -1)         speed += 5


How to show that  direct product of $\mathbb Z\times\mathbb Z\times\mathbb Z\times...$ is not projective as a $\mathbb Z$ module?  I know that $\mathbb Z$ is a free $\mathbb Z$ module since it has $\{1\}$ as a basis.  An $R-$  module $P$ is said to  projective if $P$ is a direct summand of  a free $R-$  module .Also an $R-$  module is free if it is isomorphic to a direct sum of copies of the underlying ring.  However I cant use these facts to arrive at my proof.How to do it?


Indian Passport. Missing entry stamp into USA

I recently traveled from India to USA. I am on H1B. I entered USA on 29th December 2016. As my Visa extension is due in August 2017, I was gathering documents for Visa Extension. It was required to provide a scanned copy of passport page with all entry and exit stamps.  Myself and my wife both travelled back from India. My wife's passport has a entry stamp with date as 29th December 2016. But the same is missing from my passport. I guess the officer missed putting the entry stamp on my passport. My I 94 reflects the correct date of entry as 29th December. Somehow I still have my boarding pass from this trip (usually I throw them once trip is complete).   Want to know what could be implications of missing entry stamp when I travel to India next time (somewhere towards early next year)? Does this impact my H1B Visa extension ? Also what can I do to correct this information on my passport?


As I understand it, inductors create a magnetic field when current flows through them, and light is an electromagnetic radiation.  So, is it possible for an inductor to generate magnetic waves of the same frequency of visible light? If no, why? If yes, has anyone attempted such an experiment?


Document.onload not working in JavaScript?

I write document.onload code inside my head tag.. but it doesn't seems to work. here is my code..   <head> <script>     document.onload = function () {         alert("Window Loaded...!!");     } </script> </head>   But if i replace  with window.onload it perfectly works!! What is the problem? Am I doing something wrong ??


Adding 3 multi-columns upside in a table

I have posted this code before. i now want to add two multi columns upside down to the same table jus like i have marked before and after table picture to make my point clear    Here is my code of picture no 1 i posted  \documentclass[journal]{IEEEtran}  \usepackage{multicol}  \usepackage{multirow}  \begin{table*}  \settowidth\rotheadsize{DIMENSIONS}  \renewcommand\multirowsetup{\centering}  \renewcommand{\arraystretch}{1.5}      \centering  \caption{Extreme Learning Machine(ELM) with kernel classifier accuracy of   combine reduced feature vectors whose individual classifier accuracy was low}      \begin{tabular}{|l|l| c |C{2.5cm}| c |C{2.5cm}|C{2cm}|C{2.5cm}|}      \hline   Algorithm      & Dimension          &  \multirow{6}{*}{\rothead{ADD THESE\\ DIMENSIONS}}              & Total after Adding Dimensions                  & Classifier                      & Dimension Reduction Technique                          & Reduced Dimension                              & Accuracy  \\       \cline{1-2} \cline{4-8}  LBP & 4D    &                  & \multirow{5}{=}{4D + 6D + 4D\\ + 3D + 4D = 21D}                      & ELM                          & \multirow{5}{=}{Eigenvalue as Dimension Estimator,                                            PCA as Dimension Reduction}                             & \multirow{5}{=}{21 dimensions reduced to   dimensions}                                 & \multirow{5}{=}{Combine accuracy of 9  dimensional                                                   reduced Feature Vector is  again 80\%}    \\      \cline{1-2} \cline{5-5}  RGLBP         & 6D    &   &   & ELM   &   &   &   \\      \cline{1-2} \cline{5-5}  BDIP   & 4D    &   &   & ELM   &   &   &   \\      \cline{1-2} \cline{5-5}  HOG      & 3D    &   &   & ELM   &   &   &   \\      \cline{1-2} \cline{5-5}  Combine and reduced     & 4D    &   &   & ELM   &   &   &    \\    fv of poor individual  &       &   &   &       &   &   &  \\     accuracy algorithms   &       &   &   &       &   &   & \\        \hline  \end{tabular}  \label{table:table6}  \end{table*}


If I call the Ackermann Function with Graham's number as both of its arguments will it be less than $g_{65}$

In  it states that      [xkcd] means calling the Ackermann function with Graham's number as the arguments just to horrify mathematicians.   $A(g_{64},g_{64})$  In  it states that      Even simply making $g_{65}$ dwarfs the number $A( A(g_{64}, g_{64}), A(g_{64}, g_{64}))$ into insignificance.   So:  Is $g_{65}$ greater than $A(g_{64}, g_{64})$?  And is it greater than $A( A(g_{64}, g_{64}), A(g_{64}, g_{64}))$?


Why are empty and non empty TikZ matrix cells not equally placed?

I wanted to draw an almost empty matrix of nodes with TikZ similar to the left most one below. All nodes would have same size (through minimum width and minimum height) and no separation between columns and rows. But when I include a text which needs two lines I obtain the central matrix and, if the text just needs one line the right most one. I don't know what's wrong. Do you? I'm using CVS version of TikZ.  \documentclass[tikz,border=2mm]{standalone} \usetikzlibrary{matrix}  \tikzset{ proces/.style={draw, minimum height=15mm, minimum width=2cm, outer sep=0pt, text width=1.5cm, align=center} }  \begin{document} \begin{tikzpicture}  \matrix (A) [matrix of nodes,nodes=proces,nodes in empty cells] {  & \\  & \\ };  \begin{scope}[xshift=4.5cm] \matrix (A) [matrix of nodes,nodes=proces,nodes in empty cells] {  & OOO OOO \\  & \\ }; \end{scope}  \begin{scope}[xshift=9cm] \matrix (B) [matrix of nodes,nodes=proces,nodes in empty cells] {  & A \\  & \\ }; \end{scope}  \end{tikzpicture} \end{document}


Why can't my Dad join my world on Windows from his Mac?

Me and my dad enjoy playing Minecraft together, but he can't join my LAN world for some reason. But, I can still join his without issues. I've tried turning my firewall off, but it didn't work. What could be the root cause of this problem?


I need to draw this kind of simple sequency diagram, but I'm not very good with TikZ:    \begin{figure}[!ht] \begin{center} \begin{tikzpicture}[node distance=2cm,auto,>=stealth']     \node[] (server) {server};     \node[left = of server] (client) {client};     \node[below of=server, node distance=5cm] (server_ground) {};     \node[below of=client, node distance=5cm] (client_ground) {};     %     \draw (client) -- (client_ground);     \draw (server) -- (server_ground);     \draw[->] ([yshift=-1cm]client.south) -- ([yshift=-1cm]server.south);     \draw[->] ([yshift=-1.5cm]server.south) -- ([yshift=-1.5cm]client.south); \end{tikzpicture}   I also want the lines to be straight and have text over them.


I have been advised to download cuda and I downloaded nvidia cuda version 6.5,yet the cycle compute showed none. what should I do?  Help me please.  I'm using windows 7  im trying to enable graphics card nvidia geforce 320


I can't figure out what the limitations are for trading technologies to my human ally.  At first I had a large list of techs to give him.  Since we are doing a co-op vs AI we decided to research in different trees and just trade each other new techs.  After several turns of this the game stopped letting me trade him tech even when I had just finished something that I knew he didn't have.  Can anyone shed some light on this?


A problem regarding the in-equality of complex numbers .

$\mathbf {The \ Problem \ is}:$ Let, $z_1,z_2 \cdots z_n$ be such that the real and imaginary parts of each $z_i$ are non-negative . Show that $$\bigg|\sum_{i=1}^n z_i\bigg| \geq \frac{1}{\sqrt2} \sum_{i=1}^n |z_i|.$$  $\mathbf {My \ approach} :$ Actually, at a very first glance, it seems that it can be proved using induction ,but I tried by using the triangular in-equality, though it didn't work .  I think there are some tricks related to it, a small hint is warmly appreciated .


Java :Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException?

I am trying to write a program for a simple calculator that just adds two numbers and shows it in a JLabel. I have managed to design a working Window, Button, etc. But if I click the Button the Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException - Error happens and I don´t know how to solve it.  Here is the code :  import java.awt.EventQueue;  public class Rechnerwin {  private JFrame frame; private JTextField textFielda; private JTextField textFieldb; private JLabel label; int A; int B; int C; String a; String b; String c;   public static void main(String[] args) {     EventQueue.invokeLater(new Runnable() {         public void run() {             try {                 Rechnerwin window = new Rechnerwin();                 window.frame.setVisible(true);             } catch (Exception e) {                 e.printStackTrace();             }         }     });  }  public Rechnerwin() {      initialize(); }   private void initialize() {     frame = new JFrame();     frame.setBounds(100, 100, 450, 300);     frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);     frame.getContentPane().setLayout(null);      textFielda = new JTextField();     textFielda.setBounds(44, 41, 86, 20);     frame.getContentPane().add(textFielda);     textFielda.setColumns(10);      textFieldb = new JTextField();     textFieldb.setBounds(307, 41, 86, 20);     frame.getContentPane().add(textFieldb);     textFieldb.setColumns(10);      JButton btnAdd = new JButton("Add");     btnAdd.addActionListener(new ActionListener() {         public void actionPerformed(ActionEvent e) {              String a = textFielda.getText();             String b = textFieldb.getText();             int A = Integer.parseInt(a);             int B = Integer.parseInt(b);             int C = A + B;             String c = Integer.toString(C);             label.setText(c);         }     });     btnAdd.setBounds(169, 85, 89, 23);     frame.getContentPane().add(btnAdd);      JLabel label = new JLabel("a");     label.setBounds(146, 184, 131, 20);     frame.getContentPane().add(label);   } }


How do I solve "Unable to fetch some archives, maybe run apt-get update or try with --fix-missing"?

I have just installed Ubuntu 18.04.3. And I wanted to update by running sudo apt update. I got  Get:1 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]       Get:2 http://security.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB] Hit:3 http://archive.ubuntu.com/ubuntu bionic InRelease                         Get:4 http://archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]     Fetched 252 kB in 28s (8,883 B/s)                                               Reading package lists... Done Building dependency tree        Reading state information... Done 4 packages can be upgraded. Run 'apt list --upgradable' to see them.   After that I ran apt list --upgradable, I got  Listing... Done libsnmp30/bionic-updates 5.7.3+dfsg-1.8ubuntu3.3 amd64 [upgradable from: 5.7.3+dfsg-1.8ubuntu3.1] linux-generic-hwe-18.04/bionic-security,bionic-updates 5.0.0.36.94 amd64 [upgradable from: 5.0.0.23.80] linux-headers-generic-hwe-18.04/bionic-security,bionic-updates 5.0.0.36.94 amd64 [upgradable from: 5.0.0.23.80] linux-image-generic-hwe-18.04/bionic-security,bionic-updates 5.0.0.36.94 amd64 [upgradable from: 5.0.0.23.80]   After this, I ran sudo apt-get upgrade, I got  Reading package lists... Done Building dependency tree        Reading state information... Done Calculating upgrade... Done The following packages have been kept back:   linux-generic-hwe-18.04 linux-headers-generic-hwe-18.04 linux-image-generic-hwe-18.04 The following packages will be upgraded:   libsnmp30 1 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Need to get 929 kB of archives. After this operation, 1,024 B of additional disk space will be used. Do you want to continue? [Y/n] y Err:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libsnmp30 amd64 5.7.3+dfsg-1.8ubuntu3.3   403  Forbidden [IP: 91.189.88.173 80] E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/n/net-snmp/libsnmp30_5.7.3+dfsg-1.8ubuntu3.3_amd64.deb  403  Forbidden [IP: 91.189.88.173 80] E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?   Here my repository:  deb http://security.ubuntu.com/ubuntu/ bionic-security multiverse main restricted universe deb http://archive.ubuntu.com/ubuntu bionic-updates multiverse main restricted universe deb http://archive.ubuntu.com/ubuntu bionic main universe restricted multiverse deb http://archive.ubuntu.com/ubuntu bionic-backports multiverse main restricted universe   How to fix with it?


How do I set my DNS when resolv.conf is being overwritten?

Most of the info I see online says to edit /etc/resolv.conf, but any changes I make there just get overridden.  $ cat /etc/resolv.conf  # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8) #     DO NOT EDIT THIS FILE BY HAND --  #     YOUR CHANGES WILL BE OVERWRITTEN nameserver 127.0.1.1   It seems that 127.0.1.1 is a local instance of dnsmasq. The dnsmasq docs say to edit /etc/resolv.conf. I tried putting custom nameservers in /etc/resolv.conf.d/base, but the changes didn't show up in /etc/resolv.conf after running sudo resolvconf -u.  FYI, I don't want to change DNS on a per-connection basis, I want to set default DNS settings to use for all connections when not otherwise specified.  UPDATE:  I answered this question myself:   I think it's the best solution since:   It works. It requires the least amount of changes and It still works in conjunction with dnsmasq's DNS cache, rather than bypassing it.


Matrix transforms with SpriteBatch overloading - how do you rotate/zoom around a point?

I have a transform matrix which works as intended for game objects I want to be completely controlled by my camera:  _transform = Matrix.Identity *     Matrix.CreateTranslation(-_position.X, -_position.Y, 0) *     Matrix.CreateRotationZ(_rotation) *     Matrix.CreateTranslation(origin.X, origin.Y, 0) *     Matrix.CreateScale(new Vector3(_zoom, _zoom, _zoom));   I expose this to my drawing and use the following SpriteBatch.Begin() overload:  sb.Begin(SpriteSortMode.Deferred,      BlendState.AlphaBlend,      SamplerState.PointClamp,      DepthStencilState.None,      RasterizerState.CullCounterClockwise,      null,      view.Transform);      This works as expected. No problems.  However, I have an object which controls it's own translation as it's a fake star field. I didn't want to have to generate potentially millions of stars to be drawn in order for it to be translated about, so the star field just loops them back to the opposite side if they past the edge of the screen. Zoom just acts really bizarrely. It's not being zoomed into the middle of the screen like it should. At some high zoom value it just swipes off the screen. I initially was having an issue with the rotation but after reordering via trial and error I was able to use the correct sequence of transforms. Here's what I'm currently doing:  _transformNoTranslation = Matrix.Identity *     Matrix.CreateTranslation(origin.X, origin.Y, 0) *     Matrix.CreateRotationZ(_rotation) *     Matrix.CreateScale(new Vector3(_zoom, _zoom, _zoom)) *     Matrix.CreateTranslation(-Origin.X, -Origin.Y, 0);   And here's what it looks like:    How do I get the zoom to work correctly?  As a side question, any ideas as to why the ship jutters at high speeds? I don't plan to ever be at those high speeds during game play so it's not a huge cause for concern. Some kind of precision error with the high translation values?


In debugging a problem the application is throwing the error: Internal error: An expression services limit has been reached. Please look for potentially complex expressions in your query, and try to simplify them. In tracing through where it happens, I found that it is happening when calling an SP that is updating only a few records.  I saw comments related to this error being related to large where clauses or large volumes of data, but I can't understand why this error is happening in SQL 2019 for an SP that only updates a few records.  The logic essentially does:  Grab the information of the record into a temp table Create a new database record with that info Call another SP that returns a pre-formatted string Update the record with some other custom info later on Call another SP that is creating another singular record  That's all that it is doing, and I'm getting this error message and it is causing problems.  Any thoughts?


HP 250 G7 RTL8821CE wifi adapter not found

I have recieved a laptop from my workplace, it had no OS on it so I installed Ubuntu 18.04.3 LTS, but unfortunately it cannot find the wifi adaptor. I am running on 5.0.0-23-generic.  02:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. RTL8821CE 802.11ac PCIe Wireless Network Adapter [10ec:c821]    Can you guys please help me enable my wifi? I can download anything with USB-Tethering


Line break in a modified proof environment (with show/hide feature)

In the recent post , Werner helped me to redefine a proof environment which can be hidden by an optional boolean argument (showProof). Without an argument, somehow the line/paragraph breaking is not correct. How can one fix this?  \documentclass{scrartcl}  \usepackage{ifthen} \usepackage{environ} \usepackage{amsthm}  \newboolean{showProof}% for showing proofs \setboolean{showProof}{true}% setting the switch \newif\ifstarttheorem  % proof environment (with hide feature) \makeatletter \providecommand{\env@proof@save@env}{} \providecommand{\env@proof@process}{} \RenewEnviron{proof}[2][showProof]{   \gdef\@tmp{#1}%   \ifthenelse{\boolean{#1}}{\par\pushQED{\qed}%     \normalfont\topsep2\p@\@plus2\p@\relax     \trivlist\item[\hskip\labelsep\sffamily\bfseries Proof~#2]\gdef\mycurrenvir{proof}\global\starttheoremtrue\mbox{}\hfill\\*\ignorespaces     \BODY}{\ignorespaces} }[\ifthenelse{\boolean{\@tmp}}{%   \gdef\mycurrenvir{\relax}   \popQED\endtrivlist\@endpefalse }{\ignorespacesafterend}] \makeatother  \begin{document} Just some text \begin{proof}   Just some text in a standard proof. As we can see, there is a problem. \end{proof} \begin{proof}[false]   Proof with optional argument set to \texttt{false}. This proof correctly does   not appear. \end{proof} \begin{proof}[showProof]{(Heading)}   Proof with optional argument (\texttt{true}) and second argument ``(Heading)'' \end{proof} \end{document}


What determines default directory permissions?

In Linux when I create a directory mkdir newdir then the newly created directory has these permissions and ownership: drwxr-xr-x  2 owner group My Question How can I make the default permissions for newly created DIRECTORIES be: drwxrwxrwx  2 owner group regardless of who created the directory? Some research I made I know that from within a Samba share you can enforce that with directory mask but what if someone goes to the terminal and makes a directory as root and then a regular user comes along and he then won't be able to create files in that directory that the root user made? I have been playing with ACLs and I understand how to make all newly created FILES have certain permissions. e.g:  setfacl -dRm u::rwX,g::rwX,o::0 newdir/ This makes all files in the newdir folder have permission: -rw-rw---- regardless of who created the file. I also learnt about "setting the directory group id bit" so that any files (or directories) created in the "newdir" directory will have group ownership equal to the group ownership of the "newdir" directory. chmod g+s newdir/ I have not been able to find out how to make the default permissions for a newly created DIRECTORY be: drwxrwxrwx  2 owner group regardless of who ever created the directory? Maybe it's something to do with umask? Can it be done with ACLs?


Current kills, but is voltage important?

We always say that a low current can kill. However my knowledge of current is the amount of Coulomb. When that is explained, there is no mention of voltage level...  However, shouldn't voltage be important too? Do we consider a voltage of 120V because this is the voltage in common wire?  Let's make an extreme supposition.  Would 1A with 1 pV still be dangerous?  If so why? Coulomb are like particle as far as I understand, so if they have no energy, why would they be so dangerous?


How to type text in TextBox and then be able to press return to click on Button?

I have a TextBox and a button. In TextBox I want to type text and then be able to click enter and press my button. When I press button I can redirect to text box by using button1.Focus();  Now if I type text and press enter nothing happens. I can use tab to switch to a button, but I just wonder if I can just press enter instead.  Any ideas?


Is there a built in function in .NET 2.0 that will take two arrays and merge them into one array?  The arrays are both of the same type. I'm getting these arrays from a widely used function within my code base and can't modify the function to return the data in a different format.  I'm looking to avoid writing my own function to accomplish this if possible.


The distance between disjoint closed sets may be zero

Let $K$ and $L$ be nonempty compact sets, and define $$d= \inf \{|x-y|: x \in K \wedge y \in L\}.$$   Show that it is possible to have $d = 0$ if we assume only that the disjoint sets $K$ and $L$ are closed (i.e. they are no longer bounded).   I was thinking that essentially this problem breaks down into where we can use the unboundedness of $K $ and $L$ in order to show that at some point $d=0$. In other words, I'm looking for an example in which this occurs so that I fulfill the requirement that "it is possible." I thought about K and L being the union of alternating bounded intervals that go on infinitely, Now, I'm simply getting lost in the proof the d can =0. I think I can find that d approaches 0. Is that sufficient?


Can massive damage kill you while at 0 HP?

The rules on  state:     Massive damage can kill you instantly. When damage reduces you to 0 hit points and there is damage remaining, you die if the remaining damage equals or exceeds your hit point maximum [...]   Does this only apply if you aren't already at 0 HP? Or rather, what happens if you are currently at 0 HP and take massive damage?


JC Higgins girls bike. Trying to identify year of manufacture

I have a JC Higgins girls bike (flightliner ??) with the serial number 502 45390 185598 that I'm trying to identify the model year. Any help?


Whenever I run sudo apt update, I get:  Malformed entry 54 in list file /etc/apt/sources.list (Component) The list of sources could not be read.


What is the difference between a consistent estimator and an unbiased estimator?  The precise technical definitions of these terms are fairly complicated, and it's difficult to get an intuitive feel for what they mean. I can imagine a good estimator, and a bad estimator, but I'm having trouble seeing how any estimator could satisfy one condition and not the other.


How to access an APFS volume on Windows machine

I have a Lacie 4TB external HDD which have 1.5 TB of data but I am not able to access it as it looks like the the file system of the volume which contains my data is Apple's File System and I cant find any way to access it from windows machine.  Please Help!!!  EDIT : Is it even possible? Or Do I need to hack my way through it? Cause I really dont wanna pay any direct/indirect singly penny to Apple.


$\lim \inf \frac{x_{n+1}}{x_n} \leq \lim \inf \sqrt[n]{x_n}$ for strictly positive real seq $\{x_n\}$

Let $\{x_n\}$ be a sequence of strictly positive real numbers. I want to show that   $$\lim \inf \frac{x_{n+1}}{x_n} \leq \lim \inf \sqrt[n]{x_n} .$$  I've tried and failed to assume the contrary to derive a contradiction. any hints?


I would like to know what is contained in the "/" directory and is it capable of utilizing 50GB. My system all the 50GB allocated to "/" had been utilized. I want to know what to delete if want to utilize the space in an efficient way? I can't see any big files in "/" .