If I have an odds ratio of 1.2 say between group A and group B but a confidence interval of (0.99,1.5) which only just about contains 1. Can I make the conclusion that there is no association between group A and group B?

Traditional statistical tests, like the two sample t-test, focus on trying to eliminate the hypothesis that there is no difference between a function of two independent samples. Then, we choose a confidence level and say that if the difference of means is beyond the 95% level, we can reject the null hypothesis. If not, we "can't reject the null hypothesis". This seems to imply that we can't accept it either. Does it mean we're not sure if the null hypothesis is true?   Now, I want to design a test where my hypothesis is that a function of two samples is the same (which is the opposite of traditional statistics tests where the hypothesis is that the two samples are different). So, my null hypothesis becomes that the two samples are different. How should I design such a test? Will it be as simple as saying that if the p-value is lesser than 5% we can accept the hypothesis that there is no significant difference?


What I want is the following:  x(t) ●-o \hat{x}(f) (The bar should be longer)  What is the name of the symbol in between and does it exist in LaTeX?

I know what my symbol or character looks like, but I don't know what the command is or which math alphabet it came from. How do I go about finding this out?


What sets apart humans from other animals? Is it rationality? Or morality? If humans are inherently rational animals then why are they so often irrational in judgments and decisions? And if humans are essentially moral animals why do they so often being at war with one another?..

Can a purely biological account of man show a superiority over other animals other than that of belonging to a later stage of evolution or of greater possibilities of action, a superiority “in his very being”?


"Tired of stuffing your phone in your bra?" Is this sentence correct, or do I need to say "into your bra"

I am not sure which of the following sentences is correct:  To put virus-resistance genes in the sweet potato. To put virus-resistance genes into the sweet potato.  Could they both be correct? If one of the sentences above is not correct, could you briefly explain why? Why could not "into" be replaced with "in" in the following sentence?  One approach that works very well is to segment the market into three different areas.  Thank you.


I want to turn the "Turn screen off when inactive for x minutes" setting (in the brightness settings) to "never" from the terminal, but I couldn't find the right command.  This will be used in a executable file to change a few settings on a Ubuntu live installation.  Edit:  Due to more involved reasons I want to change this specific setting which is independent of the screen saver settings (I think).

After a fresh install of Ubuntu 12.10, my screen still goes off after about ten minutes.  I've been to the Brightness and Lock control panel.  The Turn screen off when inactive for: setting is set to Never.  I've been through the dconf editor searching for power, screen, and idle changing parameters.  This doesn't seem to have any effect on the display timeout.  Here's one more interesting thing, the screen doesn't go off, it just goes black.  The back lighting is still on, and all the pixels are black.    When it goes black, it does a very pleasant quick dim to black. Similarly, it quickly un-dim's after a key press, mouse movement, or mouse click.


I'm using Ubuntu 16.04 with Bash and I tried to read in , in  and in , but I failed to understand the meaning of "command substitution" in shell-scripting in general, and in Bash in particular, as in:  $(command)   or   `command`   What is the meaning of this term?  Edit: When I first published this question I already knew the pure concept of substitution and also the Linux concept of  (replacing a variable with its value by execution), yet I still missed the purpose of this shell feature from the documentation for whatever reason or group of reasons.    My answer after question locked  Command substitution is an operation with dedicated syntax to both execute a command and to have this command's output hold (stored) by a variable for later use.  An example with date:  thedate="$(date)"   We can then print the result using the command printf:  printf 'The date is %s\n' "$thedate"    The command substitution syntax is $(). The command itself is date. Combining both we get $(date), its value is the result of the substitution (that we could get after ). We save that value in a variable, $thedate, for later use. We display the output value held by the variable with printf, per the command above.   Note: \n in printf is a line-break.

I came across the following command:  sudo chown `id -u` /somedir   and I wonder: what is the meaning of the ` symbol. I noticed for instance that while the command above works well, the one below does not:  sudo chown 'id -u' /somedir


This is from my data structure class, We were asked to add two numbers represented by linked list. The numbers are backward, which means the least significant digit is at the front of the list. This program runs fine when the sum is less than 10. but when I have something like 9+2, eclipse shows this "Exception in thread "main" java.lang.NullPointerException"     Here is the constructor      DigitNode(int digit, DigitNode next) {             this.digit = digit;             this.next = next;     }  public static BigInteger add(BigInteger first, BigInteger second) {          BigInteger newList = new BigInteger();            DigitNode ptrF = first.front;            DigitNode ptrS = second.front;            DigitNode ptr = newList.front;             if(first.negative == second.negative) {//both positive or negative                   newList.negative = first.negative;                    int sum = 0;                   int carry = 0;                   int Fvalue= 0;                   int Svalue = 0;                    while(ptrF != null ||ptrS != null || carry != 0) {                       sum = 0;                       if (ptrF == null) {                           Fvalue = 0;                       } else {                           Fvalue = ptrF.digit;                       }                        if (ptrS == null) {                           Svalue = 0;                       } else {                           Svalue = ptrS.digit;                       }                          sum = Fvalue + Svalue + carry;                       carry = 0;                        if(sum > 9) {                           sum = sum%10 + carry;                           carry = 1;                       }                       if(newList.numDigits == 0) {newList.front = new DigitNode(sum,newList.front); newList.numDigits++;}                       else {                         ptr.next = new DigitNode(sum, null);                       ptr = ptr.next;                       newList.numDigits++;                    }                              }}             System.out.println("Parsing result:");             System.out.println("Number of Digits: " + newList.numDigits);             for (DigitNode ptrtest = newList.front; ptrtest != null; ptrtest = ptrtest.next) {                 System.out.print(ptrtest.digit + " - > ");             }             System.out.println();            return newList;      }   I'm getting the warning at this line " ptr.next = new DigitNode(sum, null);"

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


I have been struggling to understand what an interface actually does.  Following is a very clear example that should be clear to other beginners.  Could somone confirm (or not) that the interface does nothing?  It acts like an elaborate comment?  Moreover, if you used the same interface in two classes, you would have to define the functions and this might be un-DRY?  Or have I missed something?  <?php interface fax{    public function dial();    public function send();    public function recieve(); }  interface printer{    public function printBlack();    public function printColor();    public function printDraft();    public function kick(); }  class printerFax implements fax, printer{    public function dial(){ }    public function send(){ }    public function recieve(){ }    public function printBlack(){ }    public function printColor(){ }    public function printDraft(){ }    public function kick(){ }  }   $object = new printerFax;  ?>   Further thoughts, to be more specific: what does the interface actually do? I asked if it is a comment - many people imply that it is. I asked if it wasn't DRY.  I have since found this example.   .  I might add it is the only example I have found in hours of searching.  Thanks for your ready responses. If a beginner arrives here, please go to question 383947. The example is not in PHP but it shows the functionality. If anyone knows an example in PHP, I would be grateful.   This still seems undry though.  Functions get repeated where they wouldn't in procedural programming.

allow you to create code which defines the methods of classes that implement it. You cannot however add any code to those methods.    allow you to do the same thing, along with adding code to the method.   Now if you can achieve the same goal with abstract classes, why do we even need the concept of interfaces?   I've been told that it has to do with OO theory from C++ to Java, which is what PHP's OO stuff is based on. Is the concept useful in Java but not in PHP? Is it just a way to keep from having placeholders littered in the abstract class? Am I missing something?


i need your help :) I have some script that start on login (I set it on Application launcher preference) but i can't see terminal. One script it's easy and make light on on my CMstorm keyboard and set numlock to ON. Another script (too long) check update for every row with Internet, but i can't able to see if the process are in download mode or if script end. I would like this script open terminal and run it into the terminal, in this case i will be able to see what script are doing.  My script is in $home/Desktop/Elaborati/script1.sh I think it's necessary to create another script that lauch script1.sh in a new gnome-terminal...but I'm not able to do it.  Can you help me please  Thank you very much

I have a Python script which I would like to execute at every startup. I can run it by adding this to the startup applications:  python3 /path/to/script.py   That works, but it doesn't open a terminal window, so I can't see the program's output. How could I make it open a terminal window and execute the script in there?  Note: I get the window to stay open with input(' ') at the end of the Python script. Thanks!


I would like to have the following structure in my SVN Repository  External    - MVC    - MVCConttrib    - NLog   I want every team member to be able to check out the External repository so nobody has to look up the SVN urls for the underlying projects, but I want the projects in the repository to be updated from their respective (external) URLs.  How can I accomplish this?  I hope my explanation is not too confusing but I don't know how else to explain it.

I am migrating a client's SourceSafe repository (3 projects) to SVN and two of the projects share source files.  (These projects are separate products - with different names and release versions, etc)  Has SVN resolved this shortcoming?  How do people generally handle this scenario?  Of the options I know about/can think of   Use the external or extern or whatever for SVN.  I hear this is not a good option for various reasons Create a new project (maybe called shared) that contains the source.  The problem with this is that we still have to get that code (it is not a library) and import it into the project somehow.  It can be shown to be the same problem as the one above and it introduces the overhead of an additional product/project. Just check in the files in both repositories and cross-update them.  This requires developers to know about the sharing and to remember to check in.  I suppose I could write a script that checks all known shared files and updates them when needed. Have one repository for the two projects that share.  This leaves me with the problem having to create a top level project/repository that contains the two and it is a problem for labeling.  I do not really want to label the top pseudo project.  (the tags, trunk and branch things are not exactly where I would want them.)   I will probably go with the last option.  Any other comments?


I'd like to find a word to encompass multiple people who share the same birthday (but were not necessarily born in the same year):     Best wishes to my <birthday-sharing friends> for a wonderful day.

What do you call two people with the same age? I'm not looking for age range or age group.


Reading package lists... Done Building dependency tree        Reading state information... Done The following packages were automatically installed and are no longer required:   android-libext4-utils android-libselinux android-libsepol libf2fs0 Use 'sudo apt autoremove' to remove them. The following additional packages will be installed:   libappindicator1 libglade2-0 libindicator7 Suggested packages:   indicator-application The following packages will be REMOVED:   linux-image-4.15.0-20-generic The following NEW packages will be installed:   libappindicator1 libglade2-0 libindicator7 linuxdcpp 0 upgraded, 4 newly installed, 1 to remove and 255 not upgraded. 6 not fully installed or removed. Need to get 1,055 kB of archives. After this operation, 3,730 kB disk space will be freed. Do you want to continue? [Y/n] y Get:1 http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 libindicator7 amd64 16.10.0+18.04.20180321.1-0ubuntu1 [21.7 kB] Get:2 http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 libappindicator1 amd64 12.10.1+18.04.20180322.1-0ubuntu1 [19.4 kB] Get:3 http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 libglade2-0 amd64 1:2.6.4-2 [44.6 kB] Get:4 http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 linuxdcpp amd64 1.1.0-4 [969 kB] Fetched 1,055 kB in 1s (1,325 kB/s) (Reading database ... 170760 files and directories currently installed.) Removing linux-image-4.15.0-20-generic (4.15.0-20.21) ... /etc/kernel/postrm.d/initramfs-tools: update-initramfs: Deleting /boot/initrd.img-4.15.0-20-generic /etc/kernel/postrm.d/zz-update-grub: Sourcing file `/etc/default/grub' /usr/sbin/grub-mkconfig: 1: /etc/default/grub: If: not found run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127 dpkg: error processing package linux-image-4.15.0-20-generic (--remove):  installed linux-image-4.15.0-20-generic package post-removal script subprocess returned error exit status 1 Errors were encountered while processing:  linux-image-4.15.0-20-generic E: Sub-process /usr/bin/dpkg returned an error code (1)   After running cat /etc/default/grub:  If you change this file, run 'update-grub' afterwards to update # /boot/grub/grub.cfg. # For full documentation of the options in this file, see: #   info -f grub -n 'Simple configuration'  GRUB_DEFAULT=0 #GRUB_HIDDEN_TIMEOUT=0 GRUB_HIDDEN_TIMEOUT_QUIET=true GRUB_TIMEOUT=10 GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset acpi_oci=\"Linux\"" GRUB_CMDLINE_LINUX=""  # Uncomment to enable BadRAM filtering, modify to suit your needs # This works with Linux (no patch required) and with any kernel that obtains # the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) #GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"  # Uncomment to disable graphical terminal (grub-pc only) #GRUB_TERMINAL=console  # The resolution used on graphical terminal # note that you can use only modes which your graphic card supports via VBE # you can see them in real GRUB with the command `vbeinfo' #GRUB_GFXMODE=640x480  # Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux #GRUB_DISABLE_LINUX_UUID=true  # Uncomment to disable generation of recovery mode menu entries #GRUB_DISABLE_RECOVERY="true"  # Uncomment to get a beep at grub start #GRUB_INIT_TUNE="480 440 1"

When I run sudo update-grub2 or sudo update-grub  I get the response     Sourcing file `/etc/default/grub'   /usr/sbin/grub-mkconfig: 1: /etc/default/grub: If: not found   However, my /etc/default/grub file is definitely there. The contents are as such:    If you change this file, run 'update-grub' afterwards to update # /boot/grub/grub.cfg. # For full documentation of the options in this file, see: #   info -f grub -n 'Simple configuration'  GRUB_DEFAULT=0 GRUB_TIMEOUT=10 GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` #Originally... #GRUB_CMDLINE_LINUX_DEFAULT="quiet splash" GRUB_CMDLINE_LINUX_DEFAULT="splash radeon.si_support=0 amdgpu.si_support=1 radeon.cik_support=0 amdgpu.cik_support=1" GRUB_CMDLINE_LINUX=""  # Uncomment to enable BadRAM filtering, modify to suit your needs # This works with Linux (no patch required) and with any kernel that obtains # the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) #GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"  # Uncomment to disable graphical terminal (grub-pc only) #GRUB_TERMINAL=console  # The resolution used on graphical terminal # note that you can use only modes which your graphic card supports via VBE # you can see them in real GRUB with the command `vbeinfo' #GRUB_GFXMODE=640x480  # Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux #GRUB_DISABLE_LINUX_UUID=true  # Uncomment to disable generation of recovery mode menu entries #GRUB_DISABLE_RECOVERY="true"  # Uncomment to get a beep at grub start #GRUB_INIT_TUNE="480 440 1"   Any clue what the error could be? Thanks!


I have been trying to create a donut to practice my Blender-skills and so far, it went pretty well. I have made a donut with icing, sprinkles (particles) and some texture (paint) and because I liked the result, I tried to render the image. However, the render leaves the icing out (see image)]! I have been searching the internet and found some solutions but none of them worked. I have made sure the render-icon in the viewport is checked and the icing should be visible to the camera (box is checked: object - visibility - camera). I have absolutely no clue on what to try next... Maybe someone here has a useful tip...? P.S. Is it possible that it has something to do with the particles? I used this donut document to make a donut before and that one rendered completely. This time I tried to make metallic looking particles and now I have this problem... That is the only thing I did different (as far as I'm aware). Every tip is much appreciated!

Learning Blender 2.8. Frosting with sprinkles Object appears in object mode but not in render. Any help would be appreciated.  Another note is that when I toggle to edit mode on the mug or plate I can see the object in edit mode. But when I toggle to edit mode on frosting with sprinkles. I doesn't show up in edit mode.


I want to produce rectangles with horizontally centered text. However the outcome of my code produces rectangles where the text is NOT centered.  \documentclass[ngerman,a4paper,25pt]{scrartcl} \usepackage[11pt]{moresize} \usepackage{babel} \usepackage{slantsc} \usepackage{array} \usepackage{amsmath} \usepackage{fix-cm} \setcounter{secnumdepth}{0} \pagestyle{empty} \usepackage{ragged2e}  \input Sanremo.fd \newcommand*\initfamilySanRemo{\usefont{U}{Sanremo}{xl}{n}} \usepackage{tikz} \input ArtNouvc.fd \newcommand*\initfamilyArtNouvc{\usefont{U}{ArtNouvc}{xl}{n}}  \usepackage{calligra} \usepackage[T1]{fontenc}  \begin{document} \begin{Center}                                                                     \foreach \n in {Heinrich, Justus, Julius}{\par    \normalfont\calligra   \begin{tikzpicture}[align=center]      % \draw (0,0) rectangle (108mm,41mm) node[pos=.5, align=center] {\Huge\fontsize{40}{70}\selectfont\n};     \node (rect) [rectangle, draw, minimum width=108mm, minimum height=41mm] at (0,0) {};     \node [below] at (rect.north) {\Huge\fontsize{40}{70}\selectfont\n};   \end{tikzpicture}   \vspace{5mm}  }   \end{Center} \end{document}   The rectangle containing 'Hendrik' shows that the centering is not perfect.    What am I doing wrong?

I'm trying out the calligra package for a wedding order of service. Just trying to make the titles look a little nicer. When I use the \centering command, however, it doesn't seem to work:  \centering Test1\\ \calligra{Test}   Produces calligraphic text that doesn't seem to be centered. Is this fixable?    Thanks all,  James


says roasted tomato and garlic, put in a jar and covered in olive oil will keep for weeks in the fridge   says 3-5 days   says olive oil can only prevent discoloration/oxidation but not spoilage/toxicity/botulism  What am I missing?

When potentially hazardous foods are cooked, it is said that cooling from 60 to 21 C should happen in 2 hours and from 21 to 5 C in 4 hours, does this not contradict the 2/4 hour rule which states that if food is in temperature danger zone should be discarded if its more than 4 hours. Reference


How do I add x days to a date in Java?  For example, my date is (dd/mm/yyyy) = 01/01/2012  Adding 5 days, the output should be 06/01/2012.

I'm working with a date in this format: yyyy-mm-dd.  How can I increment this date by one day?


As 'advice' is an uncountable noun, hence should not be used as plural, but  I have a sentence here which has word 'advices' and marked as NO ERROR without any proper explanation.   They are awaiting advices from their Singapore branch.   Note: I have gone through this question but does not able understand.

"Some advice" or "some advices" as in "I got some advice / advices for you"? So, Which is correct?  In , "advice" is uncountable noun, so "Some advice"  is the correct one.  However, googling "some advices" returns 400K results and in fact many formal English articles / news use "some advices" as in this article on Yahoo News: "".     Although graduating from college is a great accomplishment which should be recognized, it is not the end. In fact, it is just the beginning of a totally new phase in life which the graduates are unfamiliar with. Below are some advices for the new graduates that are not thought in schools.   So, I think "some advices" could be accepted as an alternative to "some advice" though it is not 100% accurate.


From my understanding your limited to 10 settlers + 1 extra settler per Charisma special point. This is PER SETTLEMENT. Including the bobble head that is a total of 22 settlers per settlement.  Does that mean someone could acquire a total of 22 settlers in each and every settlement of the game before reaching the upper maximum?

I've got two settlements on the go that I'm paying attention to - Sanctuary and the Starlight Drive In. Both of these settlements have radio towers and beds and all resources in the green however they appear to have stopped growing at 10 people in each settlement even though happiness is above 80 and I've got 15+ beds at each location.  What is the maximum number of people that will join a settlement?


I tried to install ubuntu-tweak. I followed these steps:  sudo add-apt-repository ppa:tualatrix/ppa  sudo apt-get update  sudo apt-get install ubuntu-tweak   But I got Unable to locate package ubuntu-tweak.  what else should I do to install ubuntu-tweak?  thanks much, bfz

I can't install Ubuntu tweak on 16.04.  I've had it on 4 previous versions of Ubuntu, so I know exactly what to do in order to install it, it just doesn't work on 16.04.  Is anyone having the same problem?  Can anyone help?


I want to install Ubuntu on my Lenovo z51 Laptop. It has a Broadcomm bcm43162 Wifi Card.  When I boot into the Live CD, it doesnt have WiFi. When I go into the terminal and try:  sudo apt install firmware-b43-installer   It installs succesfully, but I still dont have a network connection.  A year ago I've managed to get it to work on my Ubuntu partition, but it got corrupted and I've forgotton how I did that.  I've tried Linux Mint, Manjaro & Ubuntu but they all don't seem to work.   Edit: Someone suggested:    But I've already stated that when I try  sudo apt install firmware-b43-installer   Nothing happens. And I can't reboot since I used the Live CD, because I want it to work first before I format my main partition.

I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible.   What are the steps to install Broadcom wireless drivers for a BCM43xx card?  I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc.    lspci -vnn | grep Network showed:   Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b]      iwconfig showed:  lo        no wireless extensions. eth0      no wireless extensions.   NOTE: Answer below is updated every time new information is added and confirmed working.


AngularJS is dependent upon JavaScript being enabled. This means that if someone visits an application or website built in AngularJS it will not render properly.  What are common conventions used to handle visitors with JavaScript disabled when using AngularJS?  Please explain why this is the case?  Included in the problem is the case of handling angular JS directives and {{data_bindings}}. So that the data does not show when the page cannot render the page.

There was a post this morning asking about how many people disable JavaScript. Then I began to wonder what techniques might be used to determine if the user has it disabled.   Does anyone know of some short/simple ways to detect if JavaScript is disabled? My intention is to give a warning that the site is not able to function properly without the browser having JS enabled.   Eventually I would want to redirect them to content that is able to work in the absence of JS, but I need this detection as a placeholder to start.


I have to use the Fn key to get the coordinates with the F3 key on Minecraft Java Edition. I would like to know how to use the F3 key without using the Fn key. I have looked in the controls and haven't found anything, I've looked for other questions like this but have not found an answer.

My keyboard doesn't have an Fn key so I can't get the coordinates to show up. I don't know how to get into the multiplayer settings and Shift + F3 doesn't work either.  How can I fix this?


I’m using Ubuntu Server 18.04.3 LTS (GNU/Linux 4.15.0-58-generic x86_64) to run a headless server for our home network.  During a recent maintenance session I noticed that I could upgrade to a 20.04 version of Ubuntu Server after updating the existing system.  When I ran the command to update the system I encountered an error, see code... I’m only somewhat proficient at the terminal, and wondered if anyone could help me to understand the right commands/process to correct these errors? Thanks… 2 packages can be upgraded. Run 'apt list --upgradable' to see them. lk@lkserver:~$ apt list --upgradable Listing... Done shim/xenial-updates 15+1552672080.a4a1fbe-0ubuntu2 amd64 [upgradable from: 15+1533136590.3beb971-0ubuntu1] wireless-regdb/xenial-updates,xenial-updates,xenial-security,xenial-security 2020.11.20-0ubuntu1~16.04.2 all [upgradable from: 2018.05.09-0ubuntu1~18.04.1] lk@lkserver:~$ sudo apt upgrade Reading package lists... Done Building dependency tree  Reading state information... Done Calculating upgrade... Done The following packages have been kept back: shim The following packages will be upgraded: wireless-regdb 1 upgraded, 0 newly installed, 0 to remove and 1 not upgraded. 6 not fully installed or removed. Need to get 0 B/10.6 kB of archives. After this operation, 1,024 B of additional disk space will be used. Do you want to continue? [Y/n] y (Reading database ... 106889 files and directories currently installed.) Preparing to unpack .../wireless-regdb_2020.11.20-0ubuntu1~16.04.2_all.deb ... Unpacking wireless-regdb (2020.11.20-0ubuntu1~16.04.2) over (2018.05.09-0ubuntu1 ~18.04.1) ... dpkg: error processing archive /var/cache/apt/archives/wireless-regdb_2020.11.20 -0ubuntu1~16.04.2_all.deb (--unpack): trying to overwrite '/lib/crda/pubkeys/sforshee.key.pub.pem', which is also in package crda 3.18-1build1 Errors were encountered while processing: /var/cache/apt/archives/wireless-regdb_2020.11.20-0ubuntu1~16.04.2_all.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

For example:  $ sudo apt-get install curl Reading package lists... Done Building dependency tree Reading state information... Done You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: bsh : Depends: libjline-java but it is not going to be installed groovy : Depends: libjline-java but it is not going to be installed rhino : Depends: libjline-java but it is not going to be installed E: Unmet dependencies.   Try 'apt-get -f install' with no packages (or specify a solution).   I get the same or similar errors when I attempt to install clojure1.3, leiningen, and several other packages.   When I try the suggestion made in the error message, this is what happens:  $ sudo apt-get -f install  Reading package lists... Done Building dependency tree        Reading state information... Done Correcting dependencies... Done The following packages were automatically installed and are no longer required:   diffstat linux-headers-3.2.0-26-generic linux-headers-3.2.0-26 dh-apparmor dkms html2text libmail-sendmail-perl libsys-hostname-long-perl Use 'apt-get autoremove' to remove them. The following extra packages will be installed:   libjline-java Suggested packages:   libjline-java-doc The following NEW packages will be installed:   libjline-java 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 23 not fully installed or removed. Need to get 0 B/72.0 kB of archives. After this operation, 129 kB of additional disk space will be used. Do you want to continue [Y/n]? Y (Reading database ... 226243 files and directories currently installed.) Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ... dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):  trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400 Errors were encountered while processing:  /var/cache/apt/archives/libjline-java_1.0-1_all.deb E: Sub-process /usr/bin/dpkg returned an error code (1)  $ sudo apt-get upgrade Reading package lists... Done Building dependency tree        Reading state information... Done You might want to run 'apt-get -f install' to correct these. The following packages have unmet dependencies:  bsh : Depends: libjline-java but it is not installed  groovy : Depends: libjline-java but it is not installed  rhino : Depends: libjline-java but it is not installed E: Unmet dependencies. Try using -f.


I'm experiencing a weird behavior using bash =~ operator. Basically what I want to do is to extract a version number from a xml file. This works: #!/bin/bash  CONTENT=$(cat some_file.xml) PATTERN='<Version>(.*)</Version>' if [[ $CONTENT =~ $PATTERN ]] then   echo ${BASH_REMATCH[1]}  fi  // prints the version number   But this doesn't: #!/bin/bash  CONTENT=$(cat some_file.xml) if [[ $CONTENT =~ '<Version>(.*)</Version>' ]] then   echo ${BASH_REMATCH[1]}  else   echo "Version not found!" fi  // prints "Version not found!"   Why does it match the regex when putting the pattern in a variable, and doesn't match when I just use the string itself?? By the way, if someone has a better way to extract the version number in such case I'd like to hear also, thanks!

The following code  number=1 if [[ $number =~ [0-9] ]] then   echo matched fi   works. If I try to use quotes in the regex, however, it stops:  number=1 if [[ $number =~ "[0-9]" ]] then   echo matched fi   I tried "\[0-9\]", too. What am I missing?  Funnily enough,  suggests this should work.  Bash version 3.2.39.


I have a small business client who has a few windows servers and many workstations but as far as I can tell only has a few valid oem licences (some mismatched like xp home when xp pro is installed) for the workstations and almost no valid licences for the servers (It came with 2000 and now has 2003). They're partially interested in going legit and becoming properly licensed but fear its going to be a large cost. Interestingly enough they also fear that they'll get hammered on not being licensed so far and would rather keep under the radar.  I can't say this is the first time I've come across this, someone gets a hold of a slipstreamed xp pro cd or an office install that includes the key and are happy when it just works.   I'm not interested in giving them a hard time or turning them in. As I said I see this in my small business clients all the time and it wouldn't behoove me to mess with their businesses. I'm just looking for a good path to get them back into legitimacy.  Anyone have experience with this?

This is a  about Licensing.    Questions on licensing are off-topic on Server Fault.  If your question has been closed as a duplicate of this question, then this is because we want to help you understand why licence questions are off topic rather than just telling you "it just is". In all likelihood, this question will not address your question directly, it was not meant to.    I have a question regarding software licensing. Can the Server Fault community please help with the following:   How many licenses do I need? Is this licensing configuration valid? What CALs do I need to be properly licensed? Can I run this product in a virtual environment? Can I downgrade this product to an earlier version? Am I entitled to feature X with license Y?


Consider the following Python code:  class Test(object):     def __init__(self,name):         self.name = name     def __enter__(self):         return self     def __exit__(self,type,value,trace):         return True  t = Test("a") with Test("b") as t:     print t.name print t.name   I would have expected the output to be b,a, but it actually is b,b.   Is there no such thing as shadowing in Python? Is this really expected behavior?

What exactly are the Python scoping rules?  If I have some code:  code1 class Foo:    code2    def spam.....       code3       for code4..:        code5        x()   Where is x found?  Some possible choices include the list below:   In the enclosing source file In the class namespace In the function definition In the for loop index variable Inside the for loop   Also there is the context during execution, when the function spam is passed somewhere else. And maybe  pass a bit differently?  There must be a simple reference or algorithm somewhere.  It's a confusing world for intermediate Python programmers.


I have some trouble when applying transparency to ipe objects - colours become much more grayish. We have for instance this example (ipe capture / final pdf capture):      The problem has definitely to do with the Adobe PDF engine, because Texmaker (the software I use to write Tex) shows the correct colors in the PDF-viewer.  Is there any way to fix this problem? Any suggestion is welcome.

I'm using pdflatex, and use \includegraphics to include content of figures from PDF. PDF are exported from InkScape.  \begin{figure} [!h]     \centering     \includegraphics[height=3cm]{fig/SUSAN.pdf} \end{figure}   Included PDF or source SVG has same colors. Green has always RGB value (0, 255, 0). Problem occurs when I include this files from LaTeX. In output PDF on some pages colorspace is darker. Even same image on other page has different colourity.  My PDF  . As you can see on page 7 (11 in PDF) USAN areas are bright green, but then on page 5 (9 in PDF) are green points on corners more darker.


Why does current chose the easy way? Is there a proper mathematical  formula about why current tends to go over a resistance which is smaller?

The current is maximum through those segments of a circuit that offer the least resistance. But how do electrons know beforehand that which path will resist their drift the least?


There a previous question on this subject   Let me recall it. There are sometimes one wants to edit BibTex's choice  of citation key. For example, for a paper by Freyd, Hoste, Lickorish, Millet, Ocneano and Yetter someone may want to cite [HOMFLY] instead of [FHL+95]. This was solved in above's question by the command  shorthand = {NewLabel}   so that the cite is labelled as [NewLabel].  My problem is getting this on a concrete example. I am using \bibliographystyle{amsalpha} and I am writing  @book{SGA6,  shorthand = {SGA6},  title = {Th\'eorie des intersections et th\'eor\`eme de {R}iemann-{R}och},  series = {Lecture Notes in Mathematics},  volume  = "225",  note = {S{\'e}minaire de G{\'e}om{\'e}trie Alg{\'e}brique du Bois-Marie 1966--1967 (SGA 6)},  publisher = {Springer-Verlag, Berlin-New York},  year = {1971}, }   However, I am getting instead of [SGA6] and I don't know why.  Does anyone know how to solve this?  Thank you very much for your help.

I want to do amsalpha style citation with BibTeX, except that I want to have manual control over the key/labels (e.g., [ABC09]). Is there an option for this?


I'm getting this error while trying to delete the zip file  Error when getting information for file '/home/silver/Downloads/Compressed/f65300fc-d02a-447f-99e0-064cae003c17_our-little.zip': No such file or directory   How do I solve this?

How can a user determine the path to an application being showed in launcher?  This is meant for non-programmers or experts, so terminal commands are not really suited for them. Why: we need to make our users able to drag files/folders on our applications, a standard OS feature entirely missing in Ubuntu.


I have defined a custom command for the name of my project; e.g. \newcommand{\projectname}{Gizmo}. When I used the command in my document, I've found that I need to place a ~ after the command in order to provide a space between the command and the text that follows.  For example in my tex document,  The \projectname is on track.   Produces the following pdf output:  The Gizmois on track.   So I have to use a tilda as follows:  The \projectname~is on track.   Which now produces the correct pdf output:  The Gizmo is on track.   Would someone please clarify what is going on and what is the correct (best practice) for dealing with this situation.

I have a definition:  \newcommand{\arnold}{Arnold Schwarzenegger}   When I refer to it by:  \arnold is a   it is rendered as:   Arnold Schwarzeneggeris a    In order to have a space in front of "is" I would need to write  \arnold\ is a   Is there some other shorter way?


let $x,y,z,w>0$,show that $$(x+y)^3+(y+z)^3+(z+w)^3+(w+x)^3\ge 8(x^2y+y^2z+z^2w+w^2x)$$  it seem use AM-GM inequality to solve it,But I can't it,Thanks


How to estimate the time of completion of following algorithm for Nth Fibonacci element?  private static double fib(double nth){          if (nth <= 2) return 1;         else return fib(nth - 1) + fib(nth - 2);     }

I understand Big-O notation, but I don't know how to calculate it for many functions. In particular, I've been trying to figure out the computational complexity of the naive version of the Fibonacci sequence:  int Fibonacci(int n) {     if (n <= 1)         return n;     else         return Fibonacci(n - 1) + Fibonacci(n - 2); }   What is the computational complexity of the Fibonacci sequence and how is it calculated?


Let $f:\mathbb R \rightarrow \mathbb R$  continuous function such that $f(x+y)=f(x)+f(y)$. Then there exist a real $r$ such that $f(x) = r x$.  My try:  with $f(\frac1q x)$:  $$f(x) = f(q\cdot\frac1q x) = f(\frac1q x+...+\frac1q x) = f(\frac1q x)+...+f(\frac1q x) = qf(\frac1q x)$$ Now $f(\frac pqx)$: Fix $y=\frac xq$ to get $$f(\frac pqx) = f(p\frac xq) = f(py) = p\,f(y) = p\,f(\frac1q x) = p\cdot\frac1qf(x)$$  and i know too that $\lim_{h \rightarrow 0} \frac{f(x + h) - f(x)}{h} = \lim_{h \rightarrow 0} \frac{f(x) + f(h) - f(x)}{h} = \lim_{h \rightarrow 0} \frac{f(h)}{h}$  here i stuck how can i conclude and find this $r$, some help please.

I need to find all functions $f:\mathbb R \rightarrow \mathbb R$ such that $f(x+y)=f(x)+f(y)$. I know that there are other questions that are asking the same thing, but I'm trying to figure this out by myself as best as possible. Here is how I started out:  Try out some cases:  $x=0:$ $$f(0+y)=f(0)+f(y) \iff f(y)=f(0)+f(y) \iff 0=f(0) $$ The same result is for when $y=0$  $x=-y:$ $$f(-y+y)=f(-y)+f(y) \iff f(0)=f(-y)+f(y) \iff 0=f(-y)+f(y)\iff \quad f(-y)=-f(y)$$ I want to extend the result of setting $x=-y$ to numbers other that $-1$, perhaps all real numbers or all rational numbers. I got a little help from reading other solutions on the next part:  Let $q=1+1+1+...+1$. Then  $$f(qx)=f((1+1+...+1)x)=f(x+x+...+x)=f(x)+f(x)+...+f(x)=qf(x)$$ I understood this part, but I don't understand why this helps me find all the functions that satisfy the requirement that $f(x+y)=f(x)+f(y)$, but here is how I went on:  Thus  $$f(qx)=qf(x)$$ and it should follow that $$f \bigg (\frac {1}{q} x\bigg)= \frac{1}{q}f(x)$$ where $q\not =0$, then it further follows that  $$f \bigg (\frac {p}{q} x\bigg)= \frac{p}{q}f(x)$$ where $\frac{p}{q}$ is rational, and lastly it further follows that  $$f (ax)= af(x)$$ where $a$ is real. Thus functions of the form $f(ax)$ where $a$ is real satisfies the requirement of  $f(x+y)=f(x)+f(y)$.  I don't know how much of what I did is correct\incorrect, and any help would be greatly appreciated. Also is there any way that I can say that functions of the form $f(ax)$ where $a$ is real are the only functions that satisfy the requirement of  $f(x+y)=f(x)+f(y)$? Or do other solutions exist?  Again, thanks a lot for any help! (Hints would be appreciated, I'll really try to understand the hints!)


I need to generate a random 2 digit number which will be concatenated to the end of a string. The number MUST be 2 digits (i.e. 00-99, nothing <10 is acceptable).  How can this be done using Java libraries in the simplest way possible?

How do I generate a random int value in a specific range? I have tried the following, but those do not work: Attempt 1: randomNum = minimum + (int)(Math.random() * maximum);  Bug: randomNum can be bigger than maximum. Attempt 2: Random rn = new Random(); int n = maximum - minimum + 1; int i = rn.nextInt() % n; randomNum =  minimum + i;  Bug: randomNum can be smaller than minimum.


I have this code: driver = ogr.GetDriverByName('KML') data = driver.Open(kmlFile) layer = data.GetLayer()  geom = nextFeature.GetGeometryRef()  print(geom.ExportToJson())  I am trying to export any kind of output like GeoJSON or WKT but; { "type": "MultiPolygon", "coordinates": [ [ [ [ 33.228451, 39.725639, 0.0 ], [ 33.18737, 39.653671, 0.0 ],  [ 33.234299, 39.644131, 0.0 ], [ 33.280369, 39.671131, 0.0 ]  the output is something like this and looks like the geometry that comes from KML file is in 3D projection or something, or at least the program thinks it is. Here is the spatial reference if you need to know: {   "$schema": "https://proj.org/schemas/v0.2/projjson.schema.json",   "type": "GeographicCRS",   "name": "WGS 84",   "datum": {     "type": "GeodeticReferenceFrame",     "name": "World Geodetic System 1984",     "ellipsoid": {       "name": "WGS 84",       "semi_major_axis": 6378137,       "inverse_flattening": 298.257223563     }   },   "coordinate_system": {     "subtype": "ellipsoidal",     "axis": [       {         "name": "Latitude",         "abbreviation": "lat",         "direction": "north",         "unit": "degree"       },       {         "name": "Longitude",         "abbreviation": "lon",         "direction": "east",         "unit": "degree"       }     ]   },   "id": {     "authority": "EPSG",     "code": 4326   } }

I'm working with kml files using Python gdal.ogr module. When I extract feature's geometry using feature.GetGeometryRef(), I get:  POLYGON ((44.184069865521963 41.971859752507207 0,44.355248797385123 41.976261187945859 0, ...  However, I do not need this Z value - I need just a plain 2D WKT. After hours of searching I found  method, but feature.GetGeometryRef().FlattenTo2D() returns None  So how do I convert 3D WKT to 2D?


The question is to find the largest integer that divides all $p^4-1$, where p is a prime greater than 5. Being asked this question, I just assume this number exists. Set $p = 7$, then $p^4-1=2400$. I don't have any background in number theory and not sure what to do next. Thank you for your help!

What is the greatest integer that divides $p^4-1$ for every prime number $p > 5$?  This was on a practice math GRE so it's probably really easy.


I want to use rsync to copy all files from subfolders with a specific file ending, keeping the folder structure at the destination. Given a folder structure, for example foo  | bar     | file1.txt     | file2.gz     | file3.py  | baz     | file4.txt  I then want to copy all files with the endings *.txt and *.py which would give me at the destination foo  | bar     | file1.txt     | file3.py  | baz     | file4.txt  I have tried using find as input to the rsync command, but this doesn't retain the folder structure. Is there some input to rsync that can do this?

I am trying to create a directory that will house all and only my PDFs compiled from LaTeX. I like keeping each project in a separate folder, all housed in a big folder called LaTeX. So I tried running:  rsync -avn *.pdf ~/LaTeX/ ~/Output/   which should find all the pdfs in ~/LaTeX/ and transfer them to the output folder. This doesn't work. It tells me it's found no matches for "*.pdf". If I leave out this filter, the command lists all the files in all the project folders under LaTeX. So it's a problem with the *.pdf filter. I tried replacing ~/ with the full path to my home directory, but that didn't have an effect.  I'm, using zsh. I tried doing the same thing in bash and even with the filter that listed every single file in every subdirectory... What's going on here?  Why isn't rsync understanding my pdf only filter?    OK. So update: No I'm trying  rsync -avn --include="*/" --include="*.pdf" LaTeX/ Output/   And this gives me the whole file list. I guess because everything matches the first pattern...


My company uses Office365, including Yammer. I downloaded the desktop app, but it got annoying so I uninstalled it (using the Add/Remove Programs util.)  It did uninstall the app, but did not completely remove the icon from the task bar. It's now just a blank white icon; the mouseover text does say Yammer, but right-clicking to try to unpin from the task bar doesn't show any kind of context menu.  Is there anywhere else I can get at the icon to be able to remove it? I'm OK with regedit if necessary, but don't know what key to look for.  I've tried all of the answers listed in the possible duplicate, and none of them work. There is no reference to the broken icon in the %AppData%\Roaming\Microsoft\Internet Explorer\Quick Launch location, and the accepted answer of left-clicking to receive an error message does nothing.

I tried the Chrome development version for a few days, didn't like it because my tabs became broken and wouldn't load properly. I changed back to the live version, but I forgot to uninstall the development version, which gave me 2 chrome icons on my task bar, but they would both load a broken version of Chrome. I then uninstalled Chrome through the control panel and reinstalled the live version, but I now have one of those broken links on my task bar (a blank page with a folded corner) that points to a version of Chrome that's no longer there. Is there a way to remove this icon?


I encrypted my phone and SD card on my Note 2. I broke that phone, but recovered the SD card. How do I decrypt the SD card to get all files out (I do have password for it) with the new phone?

I encrypted both my phone and SD card upon purchasing my HTC Evo 4g LTE.  Recently the phone died (would get to the login screen and then reboot).  After a factory reset the SD card shows up as damaged.  I've tried mounting it in various ways, but neither the phone nor a computer will attempt to mount the drive - they just ask to format it.  Is there any hope of recovering the contents?


I recently bought a PC Controller. It wasn't working with The Amazing Spiderman 2. I updated all the drivers and stuff but all in vain. I did some research and found that the games require a Xiinput file thingy. I placed it in the game directory and the controller worked smoothly on TASM2. I brought Batman AO yesterday. I pasted the files in the game's directory but IS ISN'T WORKING. Is it a problem with my controller or with the game? Thanks in advance.

I have an Elecom Wireless Gamepad, and a Windows 7 PC (64bit). I bought Batman: Arkham Origins through steam. My Elecom didn't work, so I borrowed a friend's USB Xbox controller. It doesn't work either.  In the steam interface, in the Store, it says that Batman: Arkham Origins has full controller support. Has a huge graphic advertising it.  When I run Steam in "Big Picture" mode, I can use my XBox controller to navigate around.  But when I start the game, there is absolutely no response to either controller.  How can I use a controller in Batman: Arkham Origins for PC?


I'm having trouble with the re package in python 3.8. Any expression I create is behaving as though I used ^ to anchor to the start of the string. For I would expect this expression to match the first digit (1), but doesn't match anything at all. re.match('\d','abc123')  Similarly, searching for specific substrings only works if the substring starts with the first character re.match('a','abc123') # works re.match('b','abc123') # does not work re.match('ab','abc123') # works  Am I missing something incredibly simple? Is there some option or flag I need to change to allow it to match substrings starting at any position?

What is the difference between the search() and match() functions in the ?  I've read the  (), but I never seem to remember it.  I keep having to look it up and re-learn it.  I'm hoping that someone will answer it clearly with examples so that (perhaps) it will stick in my head.  Or at least I'll have a better place to return with my question and it will take less time to re-learn it.


I'm manually creating a sprite sheet using Photoshop and many of the graphic elements have drop shadows applied. Given that fact, it's tough at times to see where the drop shadows begin and end. I don't want to set my guides too close and cut off parts of the shadow. Anyone have any tips on how they go about handling this issue?

I want to use one of the Adobe Creative Suite 5 programs to create an image sprite of all the small icons and images on my webpages.   I've done it a number of times before in Photoshop but can't quite get every icon to be at the exact coordinates I intend them to be at.  The last method I used was to explicitly define the correct size of each as a shape, and use snap-to and line guides to line them all up where I want each image, and then insert the images and hide the shapes.   This takes a little while and to my dismay, there always seems to be something that's a pixel or two out of place, messing with my beautiful site designs.  What method can I use to set up a grid of images with varying sizes to be at specific coordinates?  Which of the Adobe CS5 Programs has the best functionality for this?  and a loosely relevant side question..  For the purpose of rendering in a browser as fast as possible, should the images be lined up vertically, horizontally or in a roughly equal sided rectangle?


I was just experimenting with calculating RSS with different horizontal lines and found something peculiar. Given a data frame, why is it that when I calculate Residual Sum of Squares for various horizontal lines, that the mean is actually the value that minimizes the RSS? For example, the mtcars data has a weight-mpg relationship. If I plot the mean of mpg and calculate the RSS for it, and likewise for other values above and below the mean, I find that it is the horizontal line that has the lowest RSS. Why is this?

I try to minimize mean squared error function defined as:  $E\left[Y - f(X)\right]^2$  I summarized the minimization procedure from different online sources (e.g.,  (p. 4),  (p. 8)) in the following lines.  First add and subtract $E[Y | X]$:  $E\left[\left\lbrace(Y - E[Y | X]) - (f(X) - E[Y|X])\right\rbrace^2\right]$  Expanding the quadratic yield:  $E\left[\left(Y - E[Y|X]\right)^2 + \left(f(X) - E[Y|X]\right)^2 - 2 \left(Y - E[Y|X]\right)\left(f(X) - E[Y|X]\right)\right]$  First term is not affected by the choice of $f(X)$; third term is $0$, so the whole expression is minimized if $f(X) = E(Y|X)$.  Question 1: I wonder what is the motivation to add and subtract $E[Y | X]$ in the first step of the procedure?  Question 2: How to explain in plain English why third term in quadratic is $0$?


I am receiving the following error in php-fpm error logs  [13-Jun-2017 23:49:31] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 32 children, there are 0 idle, and 131 total children [13-Jun-2017 23:49:32] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 32 children, there are 0 idle, and 161 total children [13-Jun-2017 23:49:33] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 32 children, there are 18 idle, and 191 total children [13-Jun-2017 23:49:46] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 8 children, there are 0 idle, and 210 total children [13-Jun-2017 23:49:47] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 16 children, there are 11 idle, and 218 total children [13-Jun-2017 23:49:48] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 32 children, there are 24 idle, and 234 total children [13-Jun-2017 23:49:49] WARNING: [pool instahd.info] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 32 children, there are 27 idle, and 240 total children  My current PHP-FPM pool setting is following pm = dynamic pm.start_servers = 35 pm.min_spare_servers = 30 pm.max_spare_servers = 70 pm.max_children = 2500 pm.max_requests = 2500  I have 64GB RAM

This is a  about capacity planning for web sites. Related:      What are some recommended tools and methods of capacity planning for web sites and web-applications? Please feel free to describe different tools and techniques for different web-servers, frameworks, etc., as well as best-practices that apply to web servers in general.


This is start layout:    And this is how it looks after I set editing table to true:    When I scroll my table down and up this looks ok:    How to update constraints on these cells once I set editing to true?  THIS QUESTION IS NOT DUPLICATD AS IT WAS MARKED. PAY ATTENTION PLEASE.

I'm using a UITableView in my iPhone app, and I have a list of people that belong to a group. I would like it so that when the user clicks on a particular person (thus selecting the cell), the cell grows in height to display several UI controls for editing the properties of that person.   Is this possible?


I usually prefer to use a functional approach in my JavaScript programming. However, since diving into WebGL, I notice the Three.js library uses constructors and prototypes.  Is there a specific reason to use the new keyword when working with 3D Graphics? Better performance? To save memory?

Could you explain the difference between setting methods in the constructor and through prototype object? The following code shows these two ways of setting the methods - say_hello and say_bye both work fine:  function MessageClass() {   this.say_bye = function() { alert('see ya'); }; }  MessageClass.prototype.say_hello = function() { alert('hello'); };  x = new MessageClass(); x.say_hello(); x.say_bye();


I've noticed that for the same pokemon at the same Power Up cost, the attacks of the XS pokemon are better than that of normal or XL.  Is there official data confirming/debunking this hypothesis?  Notice, that this is a different question to the one . That question is focused on the size of the pokemon--and mentions that larger pokemon have higher health. My question here is then, do smaller pokemon have higher attack power? If there's no health benefit, then does this mean that there's an attack bonus?

Whilst checking my Pokémon, I saw one Pidgey with very small CP value in comparison to his brethren. I noticed his weight is smaller, and he has an "XS" mark (see the screenshot).   Is this special? Can I do something with it? Is it more valuable?


I have a text that is written in uppercase. Example:  THIS IS UPPERCASE   What I want is to make it look like this (capitalize it):  This Is Uppercase   I just found out I cannot do it with CSS since text-transform: capitalize only works on the first letter, so the output is still:  THIS IS UPPERCASE   Is there any way with jquery to achieve this effect?  EDIT:  This is my HTML code:

NAME SURNAME

   NAME and SURNAME are dynamic variables, but some of the data is written in UPPERCASE, some is written in lowercase and some is written in Capitalize. I just want to uniform the names with Capitalize, possibly including the javascript in my html file, but I have trouble capitalizing strings written in uppercase.

Is there a simple way to convert a string to Title Case? E.g. john smith becomes John Smith. I'm not looking for something complicated like , just (hopefully) some kind of one- or two-liner.


Can you tell me what is the difference between these , and which one is correct:  girl problems. girls' problems.  Microsoft products Microsoft's products

Milk from goats is available in supermarkets. On the shelves of our local store in England, I have found cartons boldly labelled all three of     Goats Milk   Goat's Milk   Goats' Milk   Most brands use no apostrophe at all, which does not seem right. Brands which use "Goat's" seem to imply that the milk comes from precisely one goat, which seems unlikely. Brands which use "Goats'" may have it right; however, every molecule of milk in the carton did, originally, come from precisely one goat, a molecule of a goat's milk.  Is there any hope of finding a "correct" position for the apostrophe in this case? Must we forever live with this example of the greengrocers [sic] apostrophe?


How does NPN transistors actually work? In the picture below, I understand that electrons flow in A as the n-p junction of the Emitter and Base is forward-biased. However, the p-n junction of Base and Collector is reverse-biased, so how does the electrons in B flow?

Another form of the question is: will joining two diodes with wires (pn-np) make a transistor-equivalent?  I read that they are not equivalent, but why?


So I was calculating  $$\lim_{n\to \infty}\frac{(2n-1)!}{(2n+1)!}$$ and couldn't solve it, so I saw the answer sheet and it said that the limit was $0$, I checked the process and they simplified the expression to  $$\lim_{n\to\infty} \frac{(2n-1)!}{(2n + 1)(2n)(2n − 1)!}$$                       and then  $$\frac{1}{(2n + 1)(2n)}$$ and said it was $0$  How did they achieved this?

I am trying to calculate the limit of  $$\lim_{n \to \infty} \frac{(2n-1)!}{(2n+1)!}$$  and I am stuck. I tried n division but that didn't work. Any help is appreciated


Sorry for possibly duplicate post, I am interested in self-studying functional analysis. To give you a hint of my background; I've taken a class on real analysis (where we covered first half of Baby Rudin) and also a class on Fourier analysis (where we used Stein's Fourier analysis together with parts of his real analysis book for measure theory and to prove a.e. type of results).  Given this background, which book would you recommend me to attack? Thanks!

I recently started studying functional analysis. I have many ebooks loaded on my laptop, but can't figure out which one to start with. I've asked my instructor, and he says there aren't any specific books to start with. Here's a brief list of the topics on our syllabus:   Normed linear spaces Banach Spaces Hilbert spaces Compact Operators Knowledge of $C[0,1],L^p[0,1]$ Continuous linear operators Hahn-Banach theorem    Open mapping and Closed Graph Theorem   Uniform Boundedness Principle   I'm seeing these topics first in my lifetime. One thing I want to ask is whether functional analysis is very difficult. Please suggest some books to start this topic which covers the above and contains some exercises. Thanks in advance.


I want to know how complex number can be used in real life. What are hidden usage of complex number in real life. Can anyone explain ?  Thank you !

I've always enjoyed solving problems in the complex numbers during my undergrad. However, I've always wondered where are they used and for what? In my domain (computer science) I've rarely seen it be used/applied and hence am curious.  So what practical applications of complex numbers exist and what are the ways in which complex  transformation helps address the problem that wasn't immediately addressable?  Way back in undergrad when I asked my professor this he mentioned that "the folks in mechanical and aerospace engineering use it a lot" but for what? (Don't other domains use it too?). I'm well aware of its use in Fourier analysis but that's the farthest I got to a 'real world application'. I'm sure that's not it.  PS: I'm not looking for the ability to make one problem easier to solve, but a bigger picture where the result of the complex analysis is used for something meaningful in the real world. A naive analogy is deciding the height of tower based on trigonometry. That's going from paper to the real world. Similarly, what is it that is analyzed in the complex world and the result is used in the real world without imaginaries clouding the problem?  The question:  is nice but covers a more mathematical perspective on interim results that make solving a problem easier. It covers different ground IMHO.


I would like to know how to create outlines for the objects created in Blender and make sure the outlines actually shows up when the file is exported into DAE format.   TIA!

Here is what it looks like in Blender Render (Not Cycles).   This is how I set it up.   Basically, I'm trying to export it, but it's not including the "Freestyle" lines. When I open up the .dae file in Finder, it looks like this:   What is wrong here? I want it to be exported (COLLIDA .dae) with the black outline. I'm seeming to think that maybe the "Freestyle" is only for the Blender Render. Am I right? How would I go about getting the black outline included in my exported model? Is it an export setting I have to tick? Thanks for any helpful answers.


So I have to either prove or disprove this inequality:  $$ \left\lVert x\right\rVert^2 - \left\lVert y\right\rVert^2 \le \left\lVert x-y\right\rVert \left\lVert x+y\right\rVert$$  I know this to be true in Hilbert space. But i cant figure out what to do in Banach space.

In a normed space $(E,\lVert \cdot\rVert)$ space we have the following inequality: $$\forall\, x,y\in E,\quad\|x\|^{2}-\|y\|^{2}\leq \lVert x-y\rVert\cdot \|x+y\|.$$ How can we prove it?


I have a free tier linux instance on AWS running a bitnami ubuntu parse dashboard that is the backend for an iOS app and website.  When I log on to my instance it says that I am using 100% of the 9.76gb available when I run the df command: df -h bitnami@ip-172-31-22-220:~/apps/parse/htdocs/logs$ df -h / Filesystem      Size  Used Avail Use% Mounted on /dev/xvda1      9.7G  9.7G     0 100% /  I have found other posts about searching for what files are filling up the file server but was hoping someone may be able to offer insights into the specific set up of AWS/Ubuntu/Bitnami parse-platform.  This is my first question on this board, so before voting down please let me know if there are ways to improve my question. For example when I noticed when running du -ah there were a series of files that looked like AWS specific log files like /usr/src/linux-aws-headers-4.4.0-1109.  Does AWS write out some files that I need to clear out or back up to S3 to keep my server from filling? My website is down because of this and I am not sure what commands I can run that will help me find what is taking up all the space.  I did some research on the du command but wasn't quite sure how I could use that to track down where the space has accumulated.  I stumbled on one log file area that I try to clean out but it was only filling up about 1.6gb.  Is there a way I can run a command on unix that will list out which directories are > a 1gb or something?  I suspect that there is another place like the folder I found du -h /home/bitnami/apps/parse/htdocs/logs where log or error files exist that need to be cleaned out and I just don't know how the ubuntu bitnami parse instance stores those things.  I am new to AWS so I am pretty sure that I need to upgrade my account or something so I have more then 9.76 gb in filespace before I release my app for general use, so you if you happen to have any advice for what an AWS instance that is the backend for an iOS should be set up as I would appreciate any insights on that topic as well.

Possible Duplicate:          I just had an old server go belly up because it ran out of drive space. I am logged in to the shell, and I'm trying to find more unused files to remove.  Is there shell a command, script, or app that will display the largest files/folders?


i would like to keep only first two digits after decimal but i don't want to round or convert the value.  For example:   143,655 -> 143.65 547934,945 -> 547934,94   Converting or rounding the values doesn't work, it modifies the values.

I'm trying to determine the best way to truncate or drop extra decimal places in SQL without rounding.  For example:  declare @value decimal(18,2)  set @value = 123.456   This will automatically round @value to be 123.46, which is good in most cases.  However, for this project, I don't need that.  Is there a simple way to truncate the decimals I don't need?  I know I can use the left() function and convert back to a decimal.  Are there any other ways?


Today I used Tune up drive defrag and after using it my free disk space decreased by 9 GB. Why did this happen. What can I do to recover the disk space? Thank you. I just found out that this is using my disk space.

How can I visualize which folders and files are taking up all of the space on my hard drive?  I'm getting some conflicting reports on the size of hard drive contents. Namely what is and isn't there and what folders are actually using the space.   I need to know which of the files or folders the culprits behind all this hidden bloat. Also there should be a print option to get it on paper.


I currently have the following object in php:   "Direction": "Please choose the direction"   "Media": "Please choose the stock"   "Coating": "Please choose the coating"  I then loop through it with a foreach foreach ($product as $key => $att) { // is there away I can get the index?  Meaning 0, 1, etc? }  In the foreach is there away I can get the index?  I need a numerical index value.

Is it possible to find the foreach index?  in a for loop as follows:  for ($i = 0; $i < 10; ++$i) {    echo $i . ' '; }   $i will give you the index.  Do I have to use the for loop or is there some way to get the index in the foreach loop?


on Centos 6.x,  I am adding some path export PATH=$PATH:/some/path  in both /etc/profile and ~/.bash_profile  but if it's not effective when I login via SSH  it only shows if I type source .bash_profile  What am I doing wrong?  (N.B. for logging via SSH I use the following alias: alias ssh-server='ssh -t user@server "cd /some/dir/ ; bash")

I have a user that has made no modifications to the $PATH in any dot-files: it is exactly the system default setting. From a login shell:  $ ssh example.com user@example.com:~$ cat /tmp/hello.hs #!/bin/bash  echo "$SHELL" echo "$PATH"  user@example.com:~$ /tmp/hello.hs /bin/bash /usr/local/bin:/usr/bin:/bin   Exactly as specified in /etc/profile. This I find rather unexpected:  $ ssh example.com '/tmp/hello.sh' /bin/bash        /usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games   Like I said, there's no modification of $PATH in ~/.bashrc, nor in /etc/bash.bashrc. No ~/.ssh/environment either. The ssh(1) declares that the environment variable PATH is     Set to the default PATH, as specified when compiling ssh.   but  from StackOverflow and this  article suggest that I should be able to influence the $PATH for a given command simply by modifying /etc/profile, one of the shell startup files, etc.   What's going on here?


Let $f_n\in L^2(\mathbf{R})$ be a sequence of square integrable functions, $f_n\to f$ almost everywhere, and $\|f_n\|_{L^2}\to \|f\|_{L^2}$. Prove that $\|f_n-f\|_{L^2}\to 0$.   I want to use the dominated convergence theorem but I don't know how to control $\|f_n\|_{L^2}^2$.

Let $1\leq p < \infty$. Suppose that    $\{f_k\} \subset L^p$ (the domain here does not necessarily have to be finite),  $f_k \to f$ almost everywhere, and  $\|f_k\|_{L^p} \to \|f\|_{L^p}$.    Why is it the case that $$\|f_k - f\|_{L^p} \to 0?$$   A statement in the other direction (i.e. $\|f_k - f\|_{L^p} \to 0 \Rightarrow \|f_k\|_{L^p} \to \|f\|_{L^p}$ ) follows pretty easily and is the one that I've seen most of the time. I'm not how to show the result above though.


Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


Prove that 41^n-14^n is a multiple of 27 I tried to factorise 41^n-14^n but 41 is a prime.  How should I go about

I did some mathematical induction problems on divisibility   $9^n$ $-$ $2^n$ is divisible by 7. $4^n$ $-$ $1$ is divisible by 3. $9^n$ $-$ $4^n$ is divisible by 5.   Can these be generalized as $a^n$ $-$ $b^n$$ = (a-b)N$, where N is an integer? But why is $a^n$ $-$ $b^n$$ = (a-b)N$ ?  I also see that $6^n$ $- 5n + 4$ is divisible by $5$ which is $6-5+4$ and $7^n$$+3n + 8$ is divisible by $9$ which is $7+3+8=18=9\cdot2$.  Are they just a coincidence or is there a theory behind?  Is it about modular arithmetic?


I'm working on a code for a word game. This method gets as an input a 2D arrays which contains words in lexicographic order, for example words in vocabularyByLetter[0] all start with an a.  It also gets three strings each one is a single character (I need it to be string not char). Then it finds all the words that start with firstLetter then it looks for words that contain the second and third letter, if the third and second are the same letter they should appear twice in the word.  My method goes through a big text but here are some examples:   input : "y" , "e" , "e"  output:  yelled yourselves found 2 words   My code returns all the words that start with the first letter, although I check the other statement.      public static void printWords(String[][] vocabularyByLetter,         String firstLetter, String secondLetter, String thirdLetter) {     int firstnum = (((int) firstLetter.charAt((0)) % 97) + 1);      int count = 0;      for (String word : vocabularyByLetter[firstnum]) {         if (secondLetter == thirdLetter) {             int counter = 0;             for (int i = 0; i < word.length(); i++) {                 if (word.charAt(i) == secondLetter.charAt(0)){                     counter++;                 }             }             if (counter==2){                 count++;                 System.out.println(word);             }          }         if (secondLetter!=thirdLetter){         if (word.contains(secondLetter) && word.contains(thirdLetter)) {             count++;             System.out.println(word);         }     }}     System.out.println("found" + count + "words");  }

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


Like this example, it shows (Intercept) and x, why not slope?  And I'm not sure x means what?  x <- c(1,4,12,34,86,99)  y <- c(12, 48, 500, 1000, 1200,3242)    plot(x, y)    lm(y~x) Coefficients: (Intercept)            x         27.65        24.73    summary(lm(formula = y ~ x))  Call: lm(formula = y ~ x)  Residuals:       1       2       3       4       5       6  -40.38  -78.57  175.60  131.56 -954.36  766.16   Coefficients:             Estimate Std. Error t value Pr(>|t|)   (Intercept)   27.652    360.332   0.077   0.9425   x             24.729      6.487   3.812   0.0189 * --- Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1  Residual standard error: 623.2 on 4 degrees of freedom Multiple R-squared:  0.7842,    Adjusted R-squared:  0.7302  F-statistic: 14.53 on 1 and 4 DF,  p-value: 0.0189

The help pages in R assume I know what those numbers mean, but I don't. I'm trying to really intuitively understand every number here. I will just post the output and comment on what I found out. There might (will) be mistakes, as I'll just write what I assume. Mainly I'd like to know what the t-value in the coefficients mean, and why they print the residual standard error.   Call: lm(formula = iris$Sepal.Width ~ iris$Petal.Width)  Residuals:      Min       1Q   Median       3Q      Max  -1.09907 -0.23626 -0.01064  0.23345  1.17532    This is a 5-point-summary of the residuals (their mean is always 0, right?). The numbers can be used (I'm guessing here) to quickly see if there are any big outliers. Also you can already see it here if the residuals are far from normally distributed (they should be normally distributed).  Coefficients:                  Estimate Std. Error t value Pr(>|t|)     (Intercept)       3.30843    0.06210  53.278  < 2e-16 *** iris$Petal.Width -0.20936    0.04374  -4.786 4.07e-06 *** --- Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1    Estimates $\hat{\beta_i}$, computed by least squares regression. Also, the standard error is $\sigma_{\beta_i}$. I'd like to know how this is calculated.  I have no idea where the t-value and the corresponding p-value come from. I know $\hat{\beta}$ should be normal distributed, but how is the t-value calculated?  Residual standard error: 0.407 on 148 degrees of freedom   $\sqrt{ \frac{1}{n-p} \epsilon^T\epsilon }$, I guess. But why do we calculate that, and what does it tell us?  Multiple R-squared: 0.134,  Adjusted R-squared: 0.1282    $ R^2 = \frac{s_\hat{y}^2}{s_y^2} $, which is $ \frac{\sum_{i=1}^n (\hat{y_i}-\bar{y})^2}{\sum_{i=1}^n (y_i-\bar{y})^2} $. The ratio is close to 1 if the points lie on a straight line, and 0 if they are random.  What is the adjusted R-squared?  F-statistic: 22.91 on 1 and 148 DF,  p-value: 4.073e-06    F and p for the whole model, not only for single $\beta_i$s as previous. The F value is $ \frac{s^2_{\hat{y}}}{\sum\epsilon_i} $. The bigger it grows, the more unlikely it is that the $\beta$'s do not have any effect at all.


I am planning to use neural networks for time series analysis and forecasting and i was looking for a reference or any textbook i can use for that purpose. It would be great if it has practical R or python code with it.

I'm new to machine learning, and I have been trying to figure out how to apply neural network to time series forecasting. I have found resource related to my query, but I seem to still be a bit lost. I think a basic explanation without too much detail would help.  Let's say I have some price values for each month over a few years, and I want to predict new price values. I could get a list of prices for the last few months, and then try to find similar trends in the past using K-Nearest-Neighbor. I could them use the rate of change or some other property of the past trends to try and predict new prices. How I can apply neural network to this same problem is what I am trying to find out.


soft and hard cheeses were left overnight in the refrigerator with the door was a bit open and the temperature was at 57degrees in the morning . Is the cheese safe to eat?

We went on vacation and while we were gone, the refrigerator in which I stored a GREAT DEAL of cheese (both hard and soft, although unopened) quit working and when we returned home, I found the cheese defrosted (I had put it in the freezer).  Is it safe to transfer to my other refrigerator?  The packages are unopened and there is no indication of spoilage.


I know intuitively that the Cross Product of two vectors $\vec{A}$ and $\vec{B}$ represents another vector $\vec{A \times B}$ perpendicular to it. In study of physics we come across this situation a lot. Hence I can visualize some applications of it    I know that the dot product of two vectors $\vec{A}$ and $\vec{B}$ is scalar quantity and also that it represents angular relationship between $\vec{A}$ and $\vec{B}$ .i.e.   If $\vec{A}$.$\vec{B} = 0$. Then $\vec{A}$ and $\vec{B}$ are perpendicular. If $\vec{A}$.$\vec{B} > 0$ (Positive). Then the angle between $\vec{A}$ and $\vec{B}$ are less than $90^o$. If $\vec{A}$.$\vec{B} < 0$ (Negative). Then the angle between $\vec{A}$ and $\vec{B}$ are greater than $90^o$.   But I won't be able to understand intuitively, What does the dot product represents. What does the magnitude of the dot product of two vectors represents.

I get the physical significance of vector addition & subtraction. But I don't understand what do dot & cross products mean?   More specifically,    Why is it that dot product of vectors $\vec{A}$ and $\vec{B}$ is defined as $AB\cos\theta$? Why is it that cross product of vectors $\vec{A}$ and $\vec{B}$ is defined as $AB\sin\theta$, times a unit vector determined from the right-hand rule?   To me, both these formulae seem to be arbitrarily defined (although, I know that it definitely wouldn't be the case).   If the cross product could be defined arbitrarily, why can't we define division of vectors? What's wrong with that? Why can't vectors be divided?


I tried to compile something like the following  but it is not compiling:  $$ \begin{array}{ccc}     [u,v]=0&,&\text{if bla}\\     [u,v]=0&,&1 \end{array} $$   I also tried  \begin{eqnarray}     [u,v]=0&,&\text{if bla}\\     [u,v]=0&,&1 \end{eqnarray}   I'm using pdflatex (Windows prompt), Version 3.1415926-1.40.10 (MiKTeX 2.8), and the compiler shows  ! Missing number, treated as zero. (to be read again)            u 1.45                    [u,v]                      =0 &,&1 ?   Sincerely, this makes no sense for me and if I delete the "]" in the second line, or if I don't use the second line in the eqnarray (or array), it compiles normally.

Whenever I try to compile a table that has a "[" as first character in a row it gives me the error:  Missing number, treated as zero. Illegal unit of measure   Example:  \begin{table}[htb]     \centering     \begin{tabular}{r|r}         [some text ] & ... \\         [some more text ] & ...     \end{tabular}     \caption{...}     \label{tab:...} \end{table}   How can I print "[" as first character in a row?


I use the beamer package. I want to achieve the following. Assume I have a slide of the following form (two elements):  XXX  YYY  XXX should be shown on all slides and always at the same position! YYY should be =A on the 2nd slide and =B on the 3rd slide. The problem with the existing overlay specifications is that the position of XXX depends on how much space is used by YYY. And this is different for YYY=A (2nd slide) and for YYY=B (3rd slide).

Sometimes I want an element on a frame to change in steps. I do this by  \only<2>{   ...   }   \only<3>{   ...   }     etc.  But this causes the frame to jump due to different sizes of the included content. How can this be avoided?


The underlying square in the following code ends up green, and not blue as I was expecting.  Are there some rules to be aware of ?  \begin{tikzpicture} \node (v1) at (0,3) {}; \node (v2) at (0,-1) {}; \node (v3) at (-3,3) {}; \node (v4) at (-3,-1) {}; \fill[color=gray!20] (-3,-1) -- (-3,3) -- (0,3) -- (0,-1) -- cycle; \fill[color=green!20] (-3,-1) -- (-3,3) -- (0,3) -- (0,-1) -- cycle; \fill[color=blue!20] (v4) -- (v3) -- (v1) -- (v2) -- cycle; \end{tikzpicture}

Can someone please explain me why the following code doesn't result in a fill?  And why, sometimes, I get such "very thin lines" artifact (that's visibile in my picture)?  \begin{tikzpicture} \node (A) at (0,0) {A}; \node (B) at (1,0) {B}; \node (C) at (1,1) {C}; \fill[red] (A) -- (B) -- (C) --cycle; \end{tikzpicture}   Here's what I get:


I'm working on a Java based project that incorporates 3 different classes, each calling items out of the previous.  Everything in this appears to be working except line 22 from Wedding.java. Person.class - builds a person object with a few attributes import java.util.Scanner; import java.time.LocalDate;  public class Person {     public String firstName = "";     protected String lastName = "";     protected LocalDate birthDate = LocalDate.now();          Scanner sc = new Scanner(System.in);          protected void setFirstName(String PersonInstance) {         System.out.println("Enter Person" + PersonInstance + " First Name >>> ");         this.firstName = sc.nextLine();     }     protected void setLastName(String PersonInstance) {         System.out.println("Enter Person" + PersonInstance + " Last Name >>> ");         this.lastName = sc.nextLine();     }     protected void setBirthDate(String PersonInstance) {         System.out.println("Enter Person" + PersonInstance + " Date of Birth (yyyy-mm-dd) >>> ");         this.birthDate = LocalDate.parse(sc.nextLine());              }          public String getFirstName() {         return this.getFirstName();     }          public String getLastName() {         return this.getLastName();     }          public LocalDate getBirthDate() {         return this.birthDate;     }          public Person(String PersonInstance) {         this.setFirstName(PersonInstance);         this.setLastName(PersonInstance);         this.setBirthDate(PersonInstance);     }      public static void main(String[] args) {         // TODO Auto-generated method stub              }  }//end  Couple.java - creates two Person objects import blah.Person;  public class Couple { public Person person1; public Person person2;          public Couple() {         Person person1 = new Person("1");         Person person2 = new Person("2");          }     public static void main(String[] args) {         // TODO Auto-generated method stub     }  }//end  And finally Wedding.java -- Sets a couple of class attributes/variables and creates a single Couple object. import java.time.LocalDate; import java.util.Scanner; import blah.Couple; public class Wedding {     protected String Location;     protected LocalDate weddingDate = LocalDate.now();     protected Couple newCouple ;          public Wedding() {         Scanner sc = new Scanner(System.in);         System.out.println("Enter Wedding Date (yyyy-mm-dd) >>> ");         this.weddingDate = LocalDate.parse(sc.nextLine());         System.out.println("Enter Location for Wedding >>> ");         this.Location = sc.nextLine();     }          public void getWeddingDetails() {         System.out.println("Location is : " + this.Location);         System.out.println("Wedding date is : " + this.weddingDate);         System.out.println(this.newCouple.person1.getFirstName());     }      public static void main(String[] args) {         // TODO Auto-generated method stub     }  } //end  A NPE is returned when running this.newCouple.person1.getFirstName() (line 22 of Wedding.java).  All other portions of this are working, so far.  The Wedding object is created, and class variables set.  The prompts from the Person objects are presented, and information stored.  Just trying to retrieve information from the Person object from the Wedding class seems to cause an issue.

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Yesterday,  I don't know how but i got up vote in all  my questions and answer in Mathematics, Physics, Chemistry and Ask Ubuntu Stack Exchange. Due to i got total around +310 reputation.   Today that serial voting was revised in Mathematics and Physics S.E. So I want to know which user has done this serial voting, Is it possible?

Is it possible to know who voted my question/answer up or down? If not, then is it possible to include this feature? By this feature we can come to know if you are being voted up by question owner or persons giving other answers to same question or just the visitors of that question thread.  Like...  If it is a group of people giving other answers, then your answer is most correct If it is readers of that question, then your answer is more popular


What is mean by $_ , It may used like this  mkdir testdirectory;cd $_   It will redirect to the new directory      testdirectory   if i use like this , echo $_   It shows      testdirectory   Which means previously created directory.Actually what it means, I don't know really

What the reason the number of lines differs?  $ head -n 100000 ./access.log > ./data/log.sample $ cat $_ | wc -l 1933424


I have Windows 7 installed on my PC and Windows Update doesn't load me upgrades to do, (he searches for endlessly). So I wondered if there is another solution to make updates, perhaps with some third-party tools or software.

I installed Windows 7 fresh and installed SP1. Now, when I try to check manually for Windows Updates it just hangs on the Checking for updates screen.    I tried running the tools in , but this did not fix the issue either:  No matter what I do it just hangs on the "Checking for updates..." screen and goes no further.


I have a command to run a python program. I do not want to run this command manually after login, I want this command should run automatically after I logged in to my ubuntu. I am using Ubuntu 16.04.  Here is the command.   sh demo_darknet_yolov3.sh   This shell script is placed in this directory  /MobileNet-YOLO-master/MobileNet-YOLO-master

How can I make an application automatically start when I have logged in?


$\frac{n}{a^n}=T_n$  So $\frac1a+\frac2{a^2}+...\infty=S_\infty$  Multiply $S_\infty$ by $\frac1a$.  $\frac1aS_\infty=\frac1{a^2}+\frac2{a^3}+...\infty$ $S_\infty-\frac1aS_\infty=\frac1a+\frac1{a^2}+...\infty$  $S_\infty=\frac{\frac1a}{1-\frac1a}\frac{a}{a-1}$  $S_\infty=\frac a{(a-1)^2}$  Is it right? And I cant quite figure out for the limited sum (till $n$). Please show how.  Edit: $x$ doesn't exist in the interval $[-1,1]$

How can I evaluate $$\sum_{n=1}^\infty\frac{2n}{3^{n+1}}$$? I know the answer thanks to , but I'm more concerned with how I can derive that answer. It cites tests to prove that it is convergent, but my class has never learned these before. So I feel that there must be a simpler method.  In general, how can I evaluate $$\sum_{n=0}^\infty (n+1)x^n?$$


I want to center below wrapper inside the parent div element with a height equal to windows view height, using CSS.  HTML

center div

   CSS  .main-header{ color: #fff; background: #16a8ec; padding: 10px; height: 100vh; position: relative; }  .wrapper{ position: absolute; left: 0px; right: 0px; transform: translate(0px, 50%); /* i used transform but it doesn't work */ -webkit-transform: translate(0px, 50%); /* i used transform but it doesn't work */ }   Please help me guys, thanks.

I want to center a div vertically with CSS. I don't want tables or JavaScript, but only pure CSS. I found some solutions, but all of them are missing Internet Explorer 6 support.
Div to be aligned vertically
   How can I center a div vertically in all major browsers, including Internet Explorer 6?


Am I allowed to answer my own question if I find out the answer by myself?  For example, if I ask a question about python and then figure out the answer do I answer my question or edit my post with the solution included.

Possible Duplicates:             For instance, it occurred to me that the question "what's the difference between using 'sudo su - username' with and without a hyphen?" might be useful to others to have an answer to.  Is it okay to ask it myself and then answer it myself, so as to include the answer to that (or any other) question on these sites.  (I assume that one would be for superuser.)  It's possible that this question might already be answered on superuser.com, but that's not the point.  Substitute any example question you want: is it okay to answer your own questions, and even to ask them with the purpose of answering them.  The only reason not to do this, that I can see, are that some might perceive it as "gaming the system" to get more points.  But the reason for it is that it improves the supply of (hopefully) good questions and answers.  And I think the points would still be fairly earned.


In the following code, I need to return b so that I can use it in another function. I tried testing to see if b would be returned but when I run def main and print(n_boxes), it gives me None. However if I changed return b to print(b) and print(n_boxes) to n-boxes, I get the correct output.     def subsets(a, b, lo):     hi = len(a)     subs_2 = []     if (lo == hi):       return b     else:       c = b[:]       b.append(a[lo])       subsets (a, c, lo + 1)       subsets (a, b, lo + 1)   def main():     boxes = [[1, 2, 3], [4, 5,6], [6, 6, 9], [3, 8, 4]]     b = []     n_boxes = subsets(boxes, b, 0)     print(n_boxes)   main()   I am not sure what I am doing wrong. I need the values for b. Thanks!  Ok so I want all possible subsets to be returned. The "def subsets" can do that. With "print b" my output is  [] [[3, 8, 4]] [[6, 6, 9]] [[6, 6, 9], [3, 8, 4]] [[4, 5, 6]] [[4, 5, 6], [3, 8, 4]] [[4, 5, 6], [6, 6, 9]] [[4, 5, 6], [6, 6, 9], [3, 8, 4]] [[1, 2, 3]] [[1, 2, 3], [3, 8, 4]] [[1, 2, 3], [6, 6, 9]] [[1, 2, 3], [6, 6, 9], [3, 8, 4]] [[1, 2, 3], [4, 5, 6]] [[1, 2, 3], [4, 5, 6], [3, 8, 4]] [[1, 2, 3], [4, 5, 6], [6, 6, 9]] [[1, 2, 3], [4, 5, 6], [6, 6, 9], [3, 8, 4]]   I want to be able to use the above subsets individually. So I am trying to find a way to return the subsets and be able to write a function that will give me subsets of length two. To clarify, I would be able to write such a function, but I would need the individual subsets first.

How do you generate all the permutations of a list in Python, independently of the type of elements in that list?  For example:  permutations([]) []  permutations([1]) [1]  permutations([1, 2]) [1, 2] [2, 1]  permutations([1, 2, 3]) [1, 2, 3] [1, 3, 2] [2, 1, 3] [2, 3, 1] [3, 1, 2] [3, 2, 1]


I'm trying to read the datasheet at  inside a google sheet. However, both IMPORTXML (1) and IMPORTHTML (2) return #N/A. Whats's wrong? (1) IMPORTXML(A1,"//div[contains(@class, 'specs-list')]") (2) IMPORTHTML(A1,"list",19)

Google Sheets has several import functions   IMPORTDATA IMPORTFEED IMPORTHTML IMPORTXML   Sometimes the above functions returns errors like #N/A Imported content is empty and would like to be sure that there isn't a problem with the resource content to be imported.  How do I know if these functions are able to get the content that I looking to import?  I know that there also exist IMPORTRANGE but that function only is able to import content from Google Sheets spreadsheets


I am controlling the fan speed on my notebook using acpi and the command:  echo level n > /proc/acpi/ibm/fan    where level n is a number between 1 and 7.   It works, and after I changed the permissions of the fan file I was able to write to it from a terminal screen.  However, when I create a new launcher to do this from the desktop it doesn't work. The above line is in the 'Command' section and I have set permissions so that the icon is executed as a program but when I double-click on it nothing happens. There are no error messages displayed.  Is there something special about using the echo command in a launcher or am I doing this totally wrong?

I put a .desktop file in ~/.config/autostart:  [Desktop Entry] Type=Application Exec=sslocal >log 2>&1 Path=/etc/shadowsocks Hidden=false NoDisplay=false X-GNOME-Autostart-enabled=true   Though sslocal ran as expected, it didn't generate log file.


I only have a small problem, which isn't really a problem, more of just an annoyance. When you drag a window around in Server 2008 R2, it just shows a outline, much like Windows 98. Here's a screenshot demonstrating what I'm talking about. I'm using the Desktop Experience feature, and Aero is turned on. Anyone know a way to fix this?

I just installed Windows Server 2008 R2, including the Desktop Experience feature, and activated the Themes service. I've activated Aero.    I have everything there, except that when I drag windows, I only see the border of the window as I'm dragging.  In other/older SKUs of Windows, there was a checkbox that I think said "Show Window Contents While Dragging", but I can't find such a checkbox on this OS.


I'm flying to Lubbock in Texas in September. I can get flights with a 2 hour 25 min layover in Newark, or a 3 hour layover in Chicago.  However, from there I have to get a connecting flight to Houston. The most I can find is a 50 minute layover there before boarding the flight to Lubbock. Will I have to go through customs at Houston as well?  If so, I guess I'll need a longer layover there?

I'm a British citizen travelling from London Heathrow (LHR) to the Hartford, Connecticut airport, and have a two hour stopover in Newark, New Jersey (EWR) on my itinerary. At what stage would I clear immigration and customs on arriving in the USA?


I recently ran do-release-upgrade to upgrade to Kubuntu 21.04 from 20.04 without issue. Other than some (expected) differences in configuration files, nothing failed. When I logged in to plasma, I was surprised to see all the sys tray's icons have been replaced with black placeholder squares -- see screenshot below. This is true even in alternative widgets, and in the the application launcher (all the icons are black squares).   There's nothing obvious in /var/log/syslog and I have an AMD gpu, which can happily run glxgears. The closest thing to a relevant error message is Jun 14 22:01:49 localhost org.kde.KScreen[6021]: kscreen.xcb.helper: Event Error:  147  I'd love some help debugging this. Does anyone have any ideas? Should I report this to the devs, or will I be a hindrance?

After upgrading from Kubuntu 20.04 to Kubuntu 20.10, I could not login as it just showed a black screen after boot. So I switched to command line and reinstalled Kubuntu desktop with sudo apt-get install --reinstall kubuntu-desktop kde-*. After that, i was able to login and can use all applications but the icons and background of input boxes of system apps have turned black as shown below  Notice the black squares at the bottom right in the system tray, they used to be icons for Volume, Network, Bluetooth, etc. I can however click them and they behave as they used to. Also the desktop apps' icons are black.  Notice the input fields at the right of Layout, Wallpaer type and also the button backgrounds of the window. After looking at some logs I noticed that Akonadi server was not starting up because of an unknown MySQL error and installed MariaDb as i read somewhere that it might help. Now I can start Akonadi server with akonadictl manually but still the same issue. I restarted plasma with kquitapp5 plasmashell && kstart5 plasmashell but still same issue. Also Akonadi does not start automatically when session begins.


I currently have a Ubuntu 20.04 installation, and I was wondering if it's possible to use Anarchy to install Arch along with that, as a dual boot.

I currently have an Ubuntu-Windows Dual boot. However, I would like to try out a new OS so I burned Linux Mint to a USB stick.   I would like to install Linux Mint and remove Ubuntu while still keeping my windows dual boot. I've already backed up my Ubuntu setup so I can wipe it out.   In the Linux Mint installer, should I choosing the "install alongside windows" option do this?


I do not have a flash drive or a CD that I can burn, what are some other ways that I could install Ubuntu on my computer (dell latitude d620)?

So basically as it stands I have a laptop which has no cd/dvd drive, and I don't have a usb drive.  The laptop has windows 7 installed with ubuntu 11.04 installed through wubi.  What I want to do is remove windows completely, and make ubuntu the only OS installed on the system.  Is there a way to do this without re-installing ubuntu? (i.e. can I take my wubi install away from windows?)  or is there a way to from inside ubuntu have it run the ubuntu iso somehow so I can just wipe the system and install it fresh? (even if it means I need to have an e.g. 2gb partition just for the image to reside in).


I've found that some Windows 8 programs such as Weather and Maps can be granted permission to access my physical location. However, I couldn't find a place to define this. Windows currently seems to guess it from my IP address or something like that.  I can tell the Weather application what my location is, but I would prefer to make use of the information being centralised and provided by the OS for convenience.

Is there a way to set my current location manually on Windows 8? I don't have a GPS module, but the device is always located at the same place. The automatic detection via network sets a place 200 kilometers from here.  I searched for a setting that allows me to set the location by hand, but I didn't find one.