I'm a total beginner when it comes to photography. I have a Nikon D3300, and want to branch out to a zoom lens. I did a little research and found a lens I wanted, the 70-300mm f/4-5.6G. I found one on eBay that was selling for £50. I was just about to bid when I read that the autofocus of this isn't compatible with my camera.  Can anybody help me out as to which Nikon zoom lens, 70-300mm, to look for that can autofocus with my camera? I don't actually have any idea what the f/4-5.6G means. I know the 70-300mm is the zoom length.  As you can see I'm a complete beginner, any help would be appreciated so that I don't have to keep looking at different posts on eBay to see if the lens I find is compatible and often not finding it.

I know my D40 doesn't have a motor in it to auto-focus lenses.  What type of lens has the motor in it? How can I know which lenses will and will not work?


You may have heard the argument "it's not can I go to the bathroom, it's may I."  If this is true, then any question such as "can you get me a glass of water?" could have the same argument applied to it. It's understood what is meant, but what is the grammatically correct way to phrase the question?

I'm a native English speaker and I've been doing some research into English grammar for a programme I'm working on. However, on looking into modal verbs, I've only just come to appreciate how subtle and complicated they are.  What is the difference between these sentences? What possible different response might one have to each?        I can go to the cinema tonight.   I could go to the cinema tonight.   I may go to the cinema tonight.   I might go to the cinema tonight.      Granted, the first of these looks more like a statement of ability or possibility than the three that follow. But in what ways does it differ from the others, since all suggest ability and possibility? And crucially, what distinguishes the other three.  Perhaps it's a matter of tone, of context, of the speaker... The question may appear quite simple but I haven't found a satisfactory answer elsewhere.    looked quite useful in that it covered levels of confidence and certainty but it was talking about the potential state of something rather than the possibility for the person who is speaking. Are there any differences in that sense?   looked at these verbs used in question form (e.g., differences between 'Can I...?' and 'May I...?') but I'm not so interested in that for now.  Any thoughts appreciated.


What is the meaning of (sudo)?.I looked for the meaning, but I could not find it.

I am wondering what sudo apt-get update does?  What does it update?


I would like to make a two wires wound on themselves like for light garland (like a spiral).  To make it easier i use a curve (i will later add bevel and array modifier). But I have a problem with mirror modifier, this modifier is very useful to create directly the second wire.  This is the expected result :  I only succeeded to make the wire mirror around the plan y=0 and not the axis y. I got :  I have also tried to mirror around a straight curve.

So I'm attempting to recreate this specific lollipop for a class. I was able to model the lollipop, but I'm unable to recreate the twist with 4 colors. I tried modeling 4 elongated cubes and using a simple deform to twist them. I got the result I wanted but it wouldn't work if I tried making it follow the spiral path. I also did a screw modifier on a circle and didn't know how to make it follow the spiral path either. How would you approach this in the most efficient way?   Edit: I made the lollipop! Thanks for the help!


Animagi are the spirit animal of a magical person. So what if a person's personality changes, will their Animagus form change as well, as Nymphadora Tonks' Patronus did? Or will it remain?

In the two examples shown of an Animagus capable of casting a corporeal Patronus (Minerva McGonagall and James Potter) both had the same animal as their Patronus and as their Animagus animal.  Now, it is also shown that extreme circumstances can change one's Patronus. I think the only example of this was Tonks, which turned from a jackrabbit into a wolf in response for her love of Lupin.  If Tonks (or any other wizard who had their Patronus change) had been an animagus, would her animagus have changed as well?


Does anyone know what this font name is? I am trying to create something similar in latex

Is it possible to identify the font used in a specific document/picture?  Answers to this question should identify:   Possible methods to do this (perhaps one answer per method) and adequately describe how to use it (as opposed to merely stating it); Ways of finding the identified fonts, if possible (free or not); and Any prerequisites associated with the method used, if required (for example, "In order to use method X, your document has to be in format Y").   This question is meant as an FAQ, based on an . Its aim is to facilitate the community with the general procedures involved in font identification. Similar cases are solved on a per-usage basis on 's  tag.


Haha, that's something different for once. Any good suggestions how to achieve an esthetic grain on renders in Cycles; to give it a retro and analogue vibe.

I know I'd probably use a combination of Noise Textures, but I have no idea how I could make it look realistic with varying combinations of random dots, scratch- and hair particles etc. I could only find some explanations on how to achieve standard film grain, nothing too detailed.


I am using the regulator TL497 in the case of I(pk)>500mA so I need an external transistor for that but in the datasheet they don't mention how to choose the transistor and its resistors does anyone has an idea about that ? Datasheet:

The picture below is on page 7 of the datasheet of TL497, it is a switching regulator that I use as an inverting regulator (it has an inverting mode) to generate -24V from 12V in input, in the first designing equation on this page I have 2 unknowns "I(pk)" and "Io max" I don't know how can I find their values ?? In the datasheet it is wrote that I(pk) maximum value is 500mA so if I(pk) in the equation means 500mA why they didn't write 500mA simply unless of I(pk) also I(pk) max value is 500mA it can be lower than that and if 500mA means the "Io max" then I(pk) value will be 3A for VI=12V and |Vo|=24V which is impossible because I(pk) max =500mA. I hope I explained well.  datasheet:


One of my players has Talon, a +1 Longsword that deals slashing damage, found in the Lost Mine of Phandelver adventure.  In regards to a creature that has "resistance to damage from non-magical weapons", does Talon deal magical or non-magical damage?

For example, if I use a magic dagger to stab a monster that is resistant or immune to piercing damage, but with no resistance or immunity to magic weapons, does it take full damage or not?


public static Long relativeTime(String dateToParse) {      SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");     sdf.setTimeZone(TimeZone.getTimeZone("UTC"));     Date d = null;     try {         d = sdf.parse(dateToParse);     } catch (ParseException e) {         e.printStackTrace();     }      SimpleDateFormat output = new SimpleDateFormat("d MMM yyyy  HH:mm");          output.setTimeZone(TimeZone.getDefault());       String formattedTime = output.format(d);     Date gg = null;     try {         gg = output.parse(formattedTime);     } catch (ParseException e) {         e.printStackTrace();     }      return gg != null ? gg.getTime() : 0; }   it is giving me error      java.lang.nullpointerexception attempt to invoke virtual    method long java.util.date.gettime on a null object reference at   java.util.calendar.settimecalendar.java1197   java.text.simpledateformat.formatimplsimpledateformat.java527   java.text.simpledateformat.formatsimpledateformat.java829   java.text.dateformat.formatdateformat.java314   co.helpdesk.faveo.pro.helper.relativetimehelper.java202   co.helpdesk.faveo.pro.frontend.adapters.ticketoverviewadapter.onbindviewholderticketoverviewadapter.java64   co.helpdesk.faveo.pro.frontend.adapters.ticketoverviewadapter.onbindviewholderticketoverviewadapter.java27   android.support.v7.widget.RecyclerView$Adapter.onBindViewHolder(RecyclerView.java:6356)

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?


My setup is: Ubuntu 16.04 with kernel 4.8.0-45, Nvidia proprietary drivers 375.39 from ppa on GeForce GTX 960, Display 1680x1050  The problem is when I wakeup from suspend. The windows have border with artefacts like on picture. The only solution is to restart lightdm service by:  sudo systemctl restart lightdm.service #restart Xserver   but this kills my open apps. Open source drivers works fine.

NB: Nvidia has released an official fix; please see ,  and/or .  Upon waking up Ubuntu 16.04 from Suspend, the following graphical glitches appear around all windows, context menus, and similar:      This is currently known to affect the following NVIDIA cards running the proprietary drivers:  NVIDIA GeForce 610M, driver version 375.39, 340.102 NVIDIA GT 630M, driver version 375.39 NVIDIA GTX 650, driver version 375.39 NVIDIA GT 740M, driver version 378.13 NVIDIA GTX 745, unknown driver version NVIDIA GTX 850M, driver version 375.39, 378.13 NVIDIA GT 940M, driver version 375.39 NVIDIA GTX 950M, unknown driver version NVIDIA GTX 960M, driver version 378.13 NVIDIA GTX 970, driver version 375.39 NVIDIA GTX 970M, driver version 375.39 NVIDIA GTX 980 TI, unknown driver version NVIDIA GTX 1060, driver version 375.26, 375.39, 378.09 NVIDIA GTX 1070, driver version 378.09  The above above list has been sourced from reports from other users here on AU,  thread, and  thread. NB: This is be no means an exclusive list. It probably effects nearly all Nvidia cards.  Furthermore, this issue has been replicated on a clean install where the only change was a software update and the installation of the latest NVIDIA drivers.  What is going on, and how can it be resolved?


My website works right on server, I took a backup from database and public_html in order to have a copy of my webstie in localhost.  I imported the database but it reported an error, some thing was wrong with content of  cache_views table, so I emptied this table and database successfully imported. I replaced public_html with the old one and configured settings.php. but it doesn't work, it reports this error :  Additional uncaught exception thrown while handling exception.  Original  PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT s.lid, t.translation, s.version FROM {locales_source} s LEFT JOIN {locales_target} t ON s.lid = t.lid AND t.language = :language WHERE s.source = :source AND s.context = :context AND s.textgroup = &#039;default&#039;; Array ( [:language] =&gt; fa [:source] =&gt; Makes the view results available as a context for use in Panels and other applications. [:context] =&gt; ) in locale() (line 684 of C:\xampp\htdocs\test\modules\locale\locale.module).   Additional:  PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: INSERT INTO {watchdog} (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9); Array ( [:db_insert_placeholder_0] =&gt; 0 [:db_insert_placeholder_1] =&gt; php [:db_insert_placeholder_2] =&gt; %type: !message in %function (line %line of %file). [:db_insert_placeholder_3] =&gt; a:6:{s:5:&quot;%type&quot;;s:12:&quot;PDOException&quot;;s:8:&quot;!message&quot;;s:455:&quot;SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT s.lid, t.translation, s.version FROM {locales_source} s LEFT JOIN {locales_target} t ON s.lid = t.lid AND t.language = :language WHERE s.source = :source AND s.context = :context AND s.textgroup = &amp;#039;default&amp;#039;; Array ( [:language] =&amp;gt; fa [:source] =&amp;gt; Makes the view results available as a context for use in Panels and other applications. [:context] =&amp;gt; ) &quot;;s:9:&quot;%function&quot;;s:8:&quot;locale()&quot;;s:5:&quot;%file&quot;;s:52:&quot;C:\xampp\htdocs\test\modules\locale\locale.module&quot;;s:5:&quot;%line&quot;;i:684;s:14:&quot;severity_level&quot;;i:3;} [:db_insert_placeholder_4] =&gt; 3 [:db_insert_placeholder_5] =&gt; [:db_insert_placeholder_6] =&gt; h t t p://localhost:81/test/ [:db_insert_placeholder_7] =&gt; [:db_insert_placeholder_8] =&gt; 127.0.0.1 [:db_insert_placeholder_9] =&gt; 1389935326 ) in dblog_watchdog() (line 154 of C:\xampp\htdocs\test\modules\dblog\dblog.module).

Recently I started getting an error every time I try and add a content no matter what type.  This is the error that shows up in the browser:     Additional uncaught exception thrown while handling exception.        Original   PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT COUNT(cid) FROM {comment} WHERE status = :status; Array ( [:status] => 0 ) in comment_count_unpublished() (line 313 of /Applications/MAMP/htdocs/modules/comment/comment.module).        Additional      PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: INSERT INTO {watchdog} (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9); Array ( [:db_insert_placeholder_0] => 1 [:db_insert_placeholder_1] => php [:db_insert_placeholder_2] => %type: !message in %function (line %line of %file). [:db_insert_placeholder_3] => a:6:{s:5:"%type";s:12:"PDOException";s:8:"!message";s:154:"SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT COUNT(cid) FROM {comment} WHERE status = :status; Array ( [:status] =&gt; 0 ) ";s:9:"%function";s:27:"comment_count_unpublished()";s:5:"%file";s:56:"/Applications/MAMP/htdocs/modules/comment/comment.module";s:5:"%line";i:313;s:14:"severity_level";i:3;} [:db_insert_placeholder_4] => 3 [:db_insert_placeholder_5] => [:db_insert_placeholder_6] => ; [:db_insert_placeholder_7] =>  [:db_insert_placeholder_8] => 127.0.0.1 [:db_insert_placeholder_9] => 1338336955 ) in dblog_watchdog() (line 154 of /Applications/MAMP/htdocs/modules/dblog/dblog.module).   I also get the following error in my php error file:     PHP Fatal error:  Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 2006 MySQL server has gone away' in /Applications/MAMP/htdocs/includes/database/database.inc:2136        Stack trace:   0 /Applications/MAMP/htdocs/includes/database/database.inc(2136): PDOStatement->execute(Array)   1 /Applications/MAMP/htdocs/includes/database/database.inc(664): DatabaseStatementBase->execute(Array, Array)   2 /Applications/MAMP/htdocs/includes/database/database.inc(2315): DatabaseConnection->query('SELECT expire, ...', Array, Array)   3 /Applications/MAMP/htdocs/includes/lock.inc(167): db_query('SELECT expire, ...', Array)   4 /Applications/MAMP/htdocs/includes/lock.inc(146): lock_may_be_available('theme_registry:...')   5 /Applications/MAMP/htdocs/includes/theme.inc(447): lock_acquire('theme_registry:...')   6 /Applications/MAMP/htdocs/includes/bootstrap.inc(427): ThemeRegistry->set(Array)   7 [internal function]: DrupalCacheArray->__destruct()   8 {main}         thrown in /Applications/MAMP/htdocs/includes/database/database.inc on line 2136   I am having a little trouble deciphering these error messages. Could anyone help me understand what's going on here?


At first I thought that the lift force of an airplane wing came from the buoyant force of the air. Thus we can calculate it's lift force using $$ F_b={\rho}gV$$   However, that does not seem to be true since this would yield a smaller number than the weight of the plane consequently the plane would be in free-fall which is not the case. Then I tried reasoning with Bernoulli's equation.  $$P_1+{\rho}gh+0.5{\rho}v_1^2=P_2+{\rho}gh+0.5{\rho}v_2^2$$ Where $v_1$ is the speed of the wind above the wing and $v_2$ is the speed below the wing. Now if I assumed that the thickness of the wing to be negligible I can simplify the equation as such  $$P_1+0.5{\rho}v_1^2=P_2+0.5{\rho}v_2^2$$  Algebraically moving things around  $$P_2-P_1=0.5{\rho}(v_1^2-v_2^2)$$ Lastly, using $\Delta PA=F$ $$(0.5{\rho}(v_1^2-v_2^2))*A=F$$ Where $F$ represents the lift force on the airplane wing. Can I set this F equal to ${\rho}vg$? Resulting in this $$(0.5{\rho}(v_1^2-v_2^2))*A={\rho}Vg$$ $$(0.5(v_1^2-v_2^2))*A=Vg$$ Would it make sense setting the lift force equal to the buoyant force? Since I keep thinking that it must be the buoyant force that lifts the wings. Otherwise there does not seem to be any other force that could hold up the plane.

What aerodynamic effects actually contribute to producing the lift on an airplane?  I know there's a common belief that lift comes from the Bernoulli effect, where air moving over the wings is at reduced pressure because it's forced to travel further than air flowing under the wings. But I also know that this is wrong, or at best a minor contribution to the actual lift. The thing is, none of the many sources I've seen that discredit the Bernoulli effect explain what's actually going on, so I'm left wondering. Why do airplanes actually fly? Is this something that can be explained or summarized at a level appropriate for someone who isn't trained in fluid dynamics?  (Links to further reading for more detail would also be much appreciated)


Why, when I use nth to change a list element, do all elements change?  (setq mlist nil) (loop for aa from 1 to 10      do         (setq mlist (append mlist (list '(0 2)))) ) (print mlist) (setf (nth 0 (nth 0 mlist)) 9) (print mlist)   Expected result:  ((9 2) (0 2) (0 2) (0 2) (0 2) (0 2) (0 2) (0 2) (0 2) (0 2))   Result I got:  ((9 2) (9 2) (9 2) (9 2) (9 2) (9 2) (9 2) (9 2) (9 2) (9 2))

After making it through the major parts of an introductory Lisp book, I still couldn't understand what the special operator (quote) (or equivalent ') function does, yet this has been all over Lisp code that I've seen.    What does it do?


I am trying to figure out the best way to go about creating a lighting engine for an old game format with BSP based geometry. I have all the relevant information about the light, R/G/B/brightness/radius all that sort. I want to go for per pixel lighting. How can I go about doing this? I have seen tutorials for simple examples like one light revolving around an object but wondered if the same concept applies when having numerous lights illuminating a level.  Also, the BSP geometry does not use lightmaps so that is out of the question.   Also, I am interested in using normal/specular and diffuse maps I generate with Crazybump if that helps influence your advice.

I am programming a graphics engine for an old game. The game uses a BSP geometry which I have rendering perfectly. For it's lights however, it simply has light instances with the standard x, y, z, rgba, brightness, type. Now I know that OpenGL has an 8 light limit. How should I go about handling multiple lights.  I am learning per fragment light just to have the concepts under my belt. I know per pixel lighting is the standard and I will eventually move there, just want to learn how to get this concept put in play as well.  I assume I will just calculate which lights are the closest and render those 8. Does anyone have any other ideas?


The one thing I dislike about "not an answer" is that the flag doesn't say what the post in the answer area is. Is it supposed to be a new question? Is it supposed to be a comment? a comment on what post? is it just a "+1"?  The flagger already did the work to determine what the post is in order to determine that an answer is what the post is not. It wouldn't help for flaggers to specify additional information in a custom flags, because:   Those flags occasionally survive the problem Those flags don't collate properly Those flags can't be used by the system, in a second time, to automate moderation (if 5 10k flaggers say the X post should be a comment on the Y answer, then they might probably be right and at the very least a moderator might be able to greenlight that in one click.)   Can we get more detailed "not an answer" flags?

I think it would make sense to split up the flag "This is not an answer" into three flag choices:   This should be a comment This should be an edit This should be a new question   If we had that, it would make it easier (and therefore more efficient) for mods to figure out what to do with answers flagged thusly.


I used a website called Seeking Arrangements and met a  sugar daddy. He asked for my email login, online banking login, routing, account number, Facebook, as well as my  address which is the only thing I gave him since it’s a PO. I’ve been extremely vague just to see if this is real.   I don’t plan to give him anything because I have only been talking to him for a few months and  I feel conflicted. I doubt that he is trying to scam me but I suspect that he has some kind of master plan. With things such as Venmo, Zelle, and Cashapp, what is the need for “put me on his payroll?”   He claims that he is in another country on a business trip.  He said that  he tried to send me a gift but he lost access to his card. He is now asking to deposit more than 10k into my account and have me wire it. Is this a l classic way of scamming people? If so, is it common that they spend months creating a relationship with you  to catfish you?

Someone is offering to pay me in a sort of sugar daddy/sugar baby arrangement. They want to make online deposits to me, and they're asking me for my online banking username and password. Is that information alone enough for them to be able to take my money out of my account, or am I safe?


I am using natbib and agsm for harvard style referencing. My related code is  \usepackage{natbib}  \bibliographystyle{agsm}   Then I am using \citep{} for citations. My problem is that in text I am getting (Author et al., 2012) and I want (Author et al., 2012). Does anyone know how to change this and get 'et al' in italics in the text?

I am using natbib and agsm for harvard-style referencing. My related code is  \usepackage{natbib} \bibliographystyle{agsm}   Then I am using \citep{} for citations. My problem is that in text I am getting     (Author et al. 2012)   but and I want     (Author et al. 2012)   Does anyone know how to change this and get 'et al' in italics in the text?  I am using TexPad and BibDesk and I have not been able to find the .bst files in Terminal.  I know that it is often correct to have the 'et al.' unitalicised but my university regulations requires italics.


I am writing my cv and with the following code   \documentclass[11pt,a4paper]{moderncv} \moderncvtheme[green]{classic}                   \usepackage[utf8]{inputenc}                   \usepackage{floatflt} \usepackage{fancyhdr}  \usepackage{geometry} \geometry{a4paper,left=2cm,right=1cm, top=2cm, bottom=1.5cm,headheight=21pt}  \usepackage{tikz}  \usepackage{wrapfig} \usepackage{lipsum}  \firstname{C} \familyname{N} \title{Curriculum vit\ae{}}               \address{}{}   \photo[128pt]{picture}           \usepackage[english]{babel}                \begin{document}   \section{studies}  \cventry{Dec 01, 2010 -- Jan 01, 2011}{student assistant}{}{}{}{chair of statistics xxxx \newline student assistant as a tutor of statistics 2 } \cventry{Jul 31, 2008 -- Sep 30, 2011}{matriculation Bachelor of Science x}{}{}{}{university of x}      \end{document}   I produce the following output    What I don't like is the line breaking of the date. In the first entry the "-" is in the second line and in the second entry it is in the first line. So I would prefer a more uniform formatting, so that the "-" is either in the first line or in the next line, but always the same and not switching. Any ideas?

I am writing my CV using moderncv package, everythig is nice but I have a problem with \cventry command. I have something like this:   (it means 2010 - now)  I would want to have this in one line, rather than in two lines. I tried looking into the moderncv style files but with no success. What can I do to achieve the effect I want?


As it shows on my code, I'm trying to make a simple JApplet with two JButtons and a JTextfield (which I haven't gotten to). Whenever I place everything on a container, I get a NullPointerException error. When I put it all on a JFrame, it works. I've made simple JApplets without placing all my components onto a JFrame before and they've worked but I can't seem to figure out why this one doesn't.   import javax.swing.*; import java.awt.Color; import java.awt.Container; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.util.*;  public class ActionListenerPractice extends JApplet implements ActionListener {      Container con;     //JFrame frame;     JPanel panel;     JButton dogButton, catButton;     JTextField descriptionField;      public static void main(String[] args)     {         new ActionListenerPractice();     }      public ActionListenerPractice()     {         init();     }      public void init()     {/*         //Create frame obj and set it         frame = new JFrame();         frame.setVisible(true);         frame.setSize(500, 500);*/          //Create panel obj and set it         panel = new JPanel();         panel.setLayout(new GridLayout(1,3));         panel.setBackground(Color.black);          //Add and set buttons         dogButton = new JButton("I choose a dog");         dogButton.addActionListener(this);         dogButton.setBackground(Color.cyan);          catButton = new JButton("I choose a cat");         catButton.addActionListener(this);         catButton.setBackground(Color.pink);          //Add buttons to panel         panel.add(dogButton);         panel.add(catButton);          //Add panel to container         con.add(panel);           //frame.add(panel);      }      public void actionPerformed(ActionEvent e)      {         if(e.getSource() instanceof JButton)         {             if(e.getSource() == dogButton)             {                 JOptionPane.showMessageDialog(null,"You want to adopt a dog");             }             else if(e.getSource() == catButton)             {                 JOptionPane.showMessageDialog(null, "You want to adopt a cat");             }         }      }  }

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 am allowing users to register an account on my site. They get a specific role using user_save().  When they log in for the first time, I have to verify the login credentials.   Is there a function to verify the login credentials? Is there a function to get the user roles?

How can I check if a user has a certain role?  I found  but it is for Drupal 6.


I have string that goes over multiple lines leading the terminal to scroll to the latest printed line. But I want to stay in the first line, so that I will be able to see the first lines but not the latest. Is that possible? e.g.:  for i in range(100):     print(f"hello {i}")   and I want to see hello 0 but the output should stay in the same shape

I'd like to do it in Python. What I'd like to do in this example in C: #include <stdio.h>  int main() {     int i;     for (i=0; i<10; i++) printf(".");     return 0; }  Output: ..........  In Python: >>> for i in range(10): print('.') . . . . . . . . . . >>> print('.', '.', '.', '.', '.', '.', '.', '.', '.', '.') . . . . . . . . . .  In Python print will add a \n or space, how can I avoid that? Now, it's just an example, don't tell me I can first build a string then print it. I'd like to know how to "append" strings to stdout.


I made an account of Stack Overflow and Stack Exchange with my Google account just a few hours ago.  I do want to use this contents (Stack Overflow, something like that), so I try to log in with my iPhone and iPad, but when I try to log in using the Google account, the message which couldn't perform this request with my account is sent on and on. How could I log in in the app Stack Overflow and Stack Exchange?  I'll write the message contains     Request failed: Could not perform this request with your account, please try logging back in. If this persists, let us know on meta.

I've been using the IOS StackExchange app for a couple of years now, without a problem. Today I got a new iPhone Xs, downloaded the app, and tried to log in using Google, the way I always do. Each time I tried, I got the error message shown below, so I'm doing what it says. All of my other Google logins on the same phone have worked fine, and my StackExchange/Google login works fine on my desktop. Is there some strange interaction among StackExchange, IOS, and Google that I'm not understanding?  I looked at , with an answer suggesting unblocking cookies in Safari. I checked, and they are not blocked. I'm at a loss.


How do you get Access Token using REST?  I'm trying to upload a folder in my Document Library using REST but it requires a Access Token in the header.  Here is the code:   public void createFolder(String digest) throws ClientProtocolException, IOException {     HttpPost request = new HttpPost(             "http://industrial-ex/sites/tifdemo/_api/Web/Folders/add('enovia/newfolder')");      request.addHeader("Content-Type", "application/json;odata=verbose");     request.addHeader("X-RequestDigest", digest);     CloseableHttpResponse response = httpClient.execute(target, request, context);     response.setHeader("Accept", "application/json;odata=verbose");     System.out.println("STATUS CODE Post Folder: " + response.getStatusLine());  }   Thanks in advance

I have a java program that uploads a file to a document libary and i have a method that creates a folder. I want the file to be uploaded to the folder but i keeps getting uploaded outside the folder.   If i call the create folder method before the upload file method I get http 403 Forbidden error  what could be the problem?      public void createFolder(String digest) throws ClientProtocolException, IOException {         HttpPost request = new HttpPost(                 "http://industrial-ex/sites/tifdemo/_api/Web/Folders/add('enovia/newfolder')");           request.addHeader("Content-Type", "application/json;odata=verbose");         request.addHeader("X-RequestDigest", digest);         CloseableHttpResponse response = httpClient.execute(target, request, context);         response.setHeader("Accept", "application/json;odata=verbose");         System.out.println("STATUS CODE Post Folder: " + response.getStatusLine());      }


If I have, for example, multiple instances of Firefox running then this command would switch between my different Firefox windows.  Would be analogue of Alt-` in Ubuntu.

Is there a shortcut in Windows 7 to switch between windows in a given application only? I very much like this feature in OS X; what is its equivalent in Windows?


This error recently appeared on my Raspberry Pi. I get this error when I try to autocomplete folder paths. It won't autocomplete commands at all. I don't get this error when I'm logged in as root.  When I do df -i I get:  Filesystem     Inodes  IUsed  IFree IUse% Mounted on /dev/root      399840 157845 241995   40% / devtmpfs       117383    394 116989    1% /dev tmpfs          118466      1 118465    1% /dev/shm tmpfs          118466    570 117896    1% /run tmpfs          118466      8 118458    1% /run/lock tmpfs          118466     10 118456    1% /sys/fs/cgroup /dev/mmcblk0p6      0      0      0     - /boot tmpfs          118466      4 118462    1% /run/user/1000   When I do df -h I get:  Filesystem      Size  Used Avail Use% Mounted on /dev/root       5.9G  5.7G     0 100% / devtmpfs        459M     0  459M   0% /dev tmpfs           463M     0  463M   0% /dev/shm tmpfs           463M  6.5M  457M   2% /run tmpfs           5.0M  4.0K  5.0M   1% /run/lock tmpfs           463M     0  463M   0% /sys/fs/cgroup /dev/mmcblk0p6   65M   21M   45M  32% /boot tmpfs            93M     0   93M   0% /run/user/1000   So it seems like my root is out of storage. I already removed files and uninstalled packages but nothing seems to change the outcome of df -h.  Please help, what am I doing wrong? Thanks in advance.  EDIT:  du -smh / gives me:  du: cannot access ‘/proc/2667/task/2667/fd/3’: No such file or directory du: cannot access ‘/proc/2667/task/2667/fdinfo/3’: No such file or directory du: cannot access ‘/proc/2667/fd/4’: No such file or directory du: cannot access ‘/proc/2667/fdinfo/4’: No such file or directory 5.7G    /

When administering Linux systems I often find myself struggling to track down the culprit after a partition goes full. I normally use du / | sort -nr but on a large filesystem this takes a long time before any results are returned.  Also, this is usually successful in highlighting the worst offender but I've often found myself resorting to du without the sort in more subtle cases and then had to trawl through the output.  I'd prefer a command line solution which relies on standard Linux commands since I have to administer quite a few systems and installing new software is a hassle (especially when out of disk space!)


I can't understand how it works.   private Person _user;  private Person User {   get   {     return _user ?? ( _user = GetUser() );   } }   The first time I refer to User property, _user is null so it returns ( _user = GetUser() )????  What am I missing?

Ran across this line of code:  FormsAuth = formsAuth ?? new FormsAuthenticationWrapper();   What do the two question marks mean, is it some kind of ternary operator? It's hard to look up in Google.


I'm a new Linux user.  I've installed Intellij Idea and Webstorm. Everything was fine. But then I changed the system language from Bangla to English(US) (I am from Bangladesh, but I prefer to see the dates in English). And since then I cannot find Intellij Idea and WebStorm in installed apps.   So I changed back to Bangla but it didn't fix the problem. If I go to the directory where I extracted the files and run the command ./idea.sh then the program runs alright, I can code there and run it. But again when I close Intellij idea then I cannot find it in the Installed application section. I also tried Software Center. But there it shows as not installed.

In older versions it was easy to create a launcher on my desktop. All I had to do is right click on my desktop and select the "create launcher" option.  How can I create such launchers now?


Prove that there does not exist a sequence $I_n=[a_n,b_n], n=1,2,\ldots $ of nonempty, pairwise disjoint intervals such that $\cup_{n}I_n=[0,1]$.   My solution -- is it correct?  My idea is that taking an open cover $\{A_{\alpha_i}\}$ of  $[0,1]$ then $(\cup_{i}A_{\alpha_i})\cap (\cup_i I_i)=\cup_{i}(A_{\alpha_i}\cap I_i)$ is a open cover of $[0,1]$ as well (correspondence to induced topology).   Moreover, $(A_{\alpha_i}\cap I_i)\cap (A_{\alpha_j}\cap I_j)=\emptyset$ with $i\ne j$.   Since $[0,1]$ is compact, there exists $N$ such that $ \cup_{i=1}^N(A_{\alpha_i}\cap I_i) \supset[0,1]$.   However, $[0,1] \supsetneq \cup_{i=1}^N(A_{\alpha_i}\cap I_i)$ since $\cup_{i=1}^N(A_{\alpha_i}\cap I_i)$ and $I_n=[a_n,b_n], n=1,2,\ldots $ of nonempty, pairwise disjoint intervals.   So, we get contradition $[0,1] \subsetneq [0,1]$.   Could you please give your idea about my solution? Thank you very much for your help.

Can you express $[0,1]$ as a countable disjoint union of closed sets, other than the trivial way of doing this?


Question: $\boxed{\text{Consider $\sum_{i=1}^{100}\tfrac{1}{i}=\tfrac{A}{B}$. Given that $\text{gcd}(A,B)=1$,  Show that $5\nmid AB$}}$

Let the sum   $$ {1+ \frac12 + \frac13 + \frac 14+ \dots +\frac1{99} + \frac 1{100}}$$  be written as $\frac AB$, where $A$ and $B$ are positive integers with no common factors. Show that neither $A$ nor $B$ is divisible by $5$.    Using Mathematica, I found the sum is $$\frac AB=\frac {14466636279520351160221518043104131447711}{2788815009188499086581352357412492142272}$$


I have a java program that contain four classes, but I'll post two just to show my object interaction. After I run it I receive AWT-EventQueue-0" java.lang.NullPointerException  I believe it because of my objects interaction. How to fix it?  public class myFrame extends JFrame {     public PanelOne P1 = new PanelOne();     public PanelTwo P2 = new PanelTwo();     public myFrame mf;      public myFrame() {         super("MyFrame");         setLayout(new BorderLayout());         add(P1,BorderLayout.CENTER );         add(P2,BorderLayout.EAST);         setSize(600,500);         setVisible(true);     }     public static void main(String args[]) {         myFrame mf = new myFrame();         mf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);     } }     public class PanelTwo extends JPanel {     private myFrame mf;      private JButton quit = new JButton("quit");     private ButtonHandler bh = new ButtonHandler();      private JRadioButton start = new JRadioButton("Start", true);     private JRadioButton stop = new JRadioButton("Stop");     private ButtonGroup group = new ButtonGroup();      public PanelTwo(){         super();         setLayout(new GridLayout(9,1));         setBackground(Color.RED);         add(new JLabel("PanelTwo"));         add(quit);         quit.addActionListener(bh);         add(start);         add(stop);         group.add(start);         start.addActionListener(bh);         group.add(stop);         stop.addActionListener(bh);     }     public PanelTwo(myFrame mf){         super();         this.mf=mf;     }     public class ButtonHandler implements ActionListener {          public void actionPerformed(ActionEvent ac){             if(ac.getSource()==quit){                 System.exit(0);             }             if(ac.getSource()==stop){                 mf.P1.timer.stop();             }             if(ac.getSource()==start){                 mf.P1.timer.start();             }         }     } }     And this is what I got: Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException     at Sep16and2014.PanelTwo$ButtonHandler.actionPerformed(PanelTwo.java:45)     at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2018)     at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2341) .........     So, it said that my mistake starts in line with mf.P1.timer.stop(); I believe I somewhere assigned a null value. How to fix it?

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?


Are there distributions where no conjugate prior exists? Is there a necessary and/or sufficient condition which guarantees the existence of a conjugate prior? Edit: Why has this question been closed? None of the two questions which are supposed to answer this question actually answers this.

Do all conjugate priors have to come from the exponential family? If not, what other families are known to have/produce conjugate priors?


I use Google Chrome as my main browser on Windows 7.    Can you make some websites believe that you are browsing their site on a mobile device, when I'm actually browsing on Google Chrome desktop?  The purpose is to generate a mobile-device optimized page, which I can then send to my friends. For example, I do facebook on desktop, but when I see an interesting post, I'd like to circulate it as a mobile-optimized link (m.facebook.com/*****), because most of my friends use smartphones. But I want this to happen with only some social media sites - facebook, twitter, etc. For all other sites, I want regular display on my monitor.  Is this possible?

Is it possible to browse the internet from a laptop so that the web sites you visit think you are browsing from a mobile device?  Say I need to connect via a very low bandwidth connection and just using the mobile version of the site is sufficient?  Currently I'm using Vista and Firefox 3.5


Any clue how to define T in this code?   public static T ToEnum<T>(this string value, T defaultValue)         {             if (string.IsNullOrEmpty(value))             {                 return defaultValue;             }              T result;             return Enum.TryParse<T>(value, true, out result) ? result : defaultValue;         }      Severity  Code    Description Project File    Line Error  CS0453  The type 'T'   must be a non-nullable value type in order to use it as parameter   'TEnum' in the generic type or method 'Enum.TryParse(string,   bool, out TEnum)'

I'm building a function to extend the Enum.Parse concept that  Allows a default value to be parsed in case that an Enum value is not found Is case insensitive  So I wrote the following: public static T GetEnumFromString<T>(string value, T defaultValue) where T : Enum {     if (string.IsNullOrEmpty(value)) return defaultValue;     foreach (T item in Enum.GetValues(typeof(T)))     {         if (item.ToString().ToLower().Equals(value.Trim().ToLower())) return item;     }     return defaultValue; }  I am getting a Error Constraint cannot be special class System.Enum. Fair enough, but is there a workaround to allow a Generic Enum, or am I going to have to mimic the Parse function and pass a type as an attribute, which forces the ugly boxing requirement to your code. EDIT All suggestions below have been greatly appreciated, thanks. Have settled on (I've left the loop to maintain case insensitivity - I am using this when parsing XML) public static class EnumUtils {     public static T ParseEnum<T>(string value, T defaultValue) where T : struct, IConvertible     {         if (!typeof(T).IsEnum) throw new ArgumentException("T must be an enumerated type");         if (string.IsNullOrEmpty(value)) return defaultValue;          foreach (T item in Enum.GetValues(typeof(T)))         {             if (item.ToString().ToLower().Equals(value.Trim().ToLower())) return item;         }         return defaultValue;     } }  EDIT: (16th Feb 2015) Christopher Currens has posted  below, which is well worth a look, and an upvote. I will remove this edit if the solution bubbles further up the page. EDIT 2: (13th Apr 2021) As this has now been addressed, and supported, since C# 7.3, I have changed the accepted answer, though full perusal of the top answers is worth it for academic, and historical, interest :)


Prove that $[0,1] \approx [-\pi,e^2]$  (The notation $\approx$ is used to denote equinumerous)  I know to prove two closed intervals are equinumerous I need to show a bijective function that will map from one interval to the other but I cannot seem to find the correct mapping.

The intervals $[0,1]$ and $[3,5]$ are equivalent.  My proof goes like this.  Proof. To show that the two sets are equivalent, we should show a bijection between them. Consider the function $f:[0,1] \to [3,5]$ such that $f(x)=2x+3$. Since $f$ is  linear, it is bijective. Therefore, the intervals $[0,1]$ and $[3,5]$ are equivalent.  I am not sure if this is right. Assuming that this is correct, is it better to show that $f$ is reflexive, symmetric, and transitive? If this is wrong, what is the right way of proving? Sorry if this is so simple.


What is the terminal code to download the latest adobe flash player on linux 16.04?

I have had significant problems with watching flash video in 64-bit Ubuntu.  Does anyone know of a good way to get flash running on the platform?


Given $f$ be  positive   and   continious  on $[0,1]$. Find    $$L=\lim_{p \rightarrow  0}   \left( \int_{0}^{1} (f(x))^p dx\right)^{1/p}  $$   My attempt  : I thinks  it will be $\max \{ f(x) : x \in [0,1]\}$  Is its  true ?

I'm given that $f \in L^1$ and $f(x) \neq 0$ a.e. and trying to prove that for q > 0  $$\lim_{q \to 0} (\int_0^1 |f|^q)^{1/q} = e^{\int_0^1 \ln|f|}$$  My work:  I took the log of both sides to reduce the problem to  $$\lim_{q \to 0} \frac{1}{q} \ln(\int_0^1 |f|^q) = \int_0^1 \ln|f|$$  Since $\ln$ is a concave function I used Jensen's inequality to show that  $$\frac{1}{q} \ln(\int_0^1 |f|^q) \geqslant \int_0^1 \frac{1}{q}\ln|f|^q = \int_0^1 \ln|f| $$  So if the limit exists, I know  $$\lim_{q \to 0} \frac{1}{q} \ln(\int_0^1 |f|^q) \geqslant \int_0^1 \ln|f|$$  Now I can't make any more progress to reverse the inequality.  Maybe I need a completely different approach.  Also what about the necessity of $f \in L^q$? Please help.


I have created a PHP and SQLi based search system. It is very basic and works how all of the ones I have found have. I just have one question. Can a very mean and angry person SQL inject my search system. The search is submitted through an HTML form in POST. Search System Code ...  require 'includes/dbh.inc.php';  $search = $_POST['search'];  $mysqli = $conn;  $query = "SELECT * FROM listings WHERE listing_name LIKE '%".$search."%'"; echo ' Listings

';   if ($result = $mysqli->query($query) and mysqli_num_rows($result) > 0) {      while ($row = $result->fetch_assoc()) {         $price = $row["listing_price"];         $name = $row["listing_name"];         $seller = $row["listing_seller"];         $picture = $row["listing_picture"];  ...

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


Greetings, I'm slowly getting used to Ubuntu; for I've been a Windows user as long as I've used any computer. I'm hoping someone can suggest a good graphics software.    I'm simply looking for one that works close to Microsoft Paint. Does Ubuntu offer anything like it?

I want something similar to "preview" in macs.  For example: I want an image editor that ONLY does simple adjustments like increase/decrease contrast, saturation, exposure, color tinting.... rotate, flip vertically, flip horizontally, make black and white, change size or format, crop.  THATS IT.  I know gimp can do all those things but its a bit overkill.  I just want to right click an image, open it with this magical program i just described, do a few quick adjustments, and then save and exit.  Nothing really fancy.  Anyone know of anything like this?  Btw I am using ubuntu 12.04 :) It rocks and I am glad I switched from mac, i just need to replace this one piece of software.


I tried to filter the ranges with moment.js but I acountred some problem to import that library (conflict with others) so, now I want to use instead date() constructor, but it doesn't work correctly.  Have you an idea why it doesn't work correctlty ?, Here is my try :  I used date() and getTime()  Some example that does'nt work when you hit :   from : 01 01 2019 to : 31 12 2019    $(function(){    //NAME   $("#name").on("keyup", function() {     var value = $(this).val().toLowerCase();     $("#my-table").find('tr').filter(function() {       $(this).toggle($(this).find('td').text().toLowerCase().indexOf(value) > -1)     });   });      //FROM   $("#from").bind("keyup change", function() {     var value = new Date($(this).val().toLowerCase()).getTime();     //console.log(value);     $("#my-table").find('tr').filter(function() {       $(this).toggle(new Date($(this).find('td:first-child').text()).getTime() >= (value))       //console.log(new Date($(this).find('td:first-child').text()).getTime());     });          //clean from     var val = $(this).val();     if(val.length === 0) {       $("#my-table").find('tr').show();     }   });      //TO   $("#to").bind("keyup change", function() {     var value = new Date($(this).val().toLowerCase()).getTime();     //console.log(value);     $("#my-table").find('tr').filter(function() {       $(this).toggle(new Date($(this).find('td:first-child').text().toLowerCase()).getTime() <= (value))     });          //clean to     var val = $(this).val();     if(val.length === 0) {       $("#my-table").find('tr').show();     }   });       }); .container input {     width:25%;     display:inline-block;     margin-bottom:20px; }  .list-group {   border:1px solid #1896f3;   padding:20px; }  .list-group td, th {   border:1px solid #1896f3;   padding:7px 100px;   text-align:center; }  th {     text-align: center !important;     font-size:14px;     text-transform:uppercase; }    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/css/bootstrap.min.css">
   Date from : <input class="form-control" id="from" type="date">   to : <input class="form-control" id="to" type="date">   <input class="form-control" id="name" type="text" placeholder="Enter your name...">

               Date	               Name

             2019-11-21	             kal

             2015-01-01	             blake

             2015-01-30	             secure

             2016-03-10	             home

             2019-05-19	             car

             2014-09-10	             yop

             2017-12-30	             wick

Can someone suggest a way to compare the values of two dates greater than, less than, and not in the past using JavaScript? The values will be coming from text boxes.


let $A = \left( \begin{array}{} 1 & 0 & 3 \\ 0 & 1 & 2 \\ 0 & 0 & 1 \end{array} \right)$  $A$ has one eigenvalue $\lambda=1$ with algebraic multiplicity $3$ but it has only two linearly independent eigenvectors $\left( \begin{array}{} 1  \\ 0  \\ 0  \end{array} \right),\left( \begin{array}{} 0 \\  1  \\ 0 \end{array} \right)$(this can be easily checked since $A-\lambda I=A-I=\left( \begin{array}{} 0 & 0 & 3 \\ 0 & 0 & 2 \\ 0 & 0 & 0 \end{array} \right)$ and both vectors are in $ker(A-I)$), so the geometric multiplicity is $2$ which is less than 3, the algebraic multiplicity.  and from here, I was told that I need to compute something like $(A-I)w=v$ to find $w$ where $v$ is the eigenvector. but I have two $v$'s, so I don't know which $v$ I should take.  and as I put $A$ in the Wolfram Alpha, I found its Jordan decomposition and there was no $\left( \begin{array}{} 1  \\ 0  \\ 0  \end{array} \right)$ in the column of $S$, such that $A=SJS^{-1}$, where $J$ is the Jordan form.   exactly how to find $S$? I'm so confused.

I'm having a lot of trouble understanding the process of finding a basis for the Jordan canonical form (the "algorithm"). My textbook (Friedberg 4E) isn't very clear, and I can't seem to find anything online.   If we consider the example $A$ = $\begin{bmatrix}6 & -2 & -1\\3 & 1 & -1\\2 & -1 & 2\end{bmatrix}$, we get the characteristic polynomial $p(t)$ = ($3 - t$)$^3$.  I understand the process of finding the matrix $J$ in $A = P^{-1}JP$, but I just can't seem to grasp finding $P$. Any clarification/explanation on the steps to do so would be incredibly helpful. Thank you.


I use both German and US American layout. For convenience, I defined a shortcut to toggle these via Scroll. I also have an indicator on the top gnome shell bar that shows the current layout.  Yet recently, I assume it has something to do with the 13.10 upgrade, pressing the shortcut does not toggle the layout in the current application even though the indicator shows the change. Strangely, going into the keyboard applet via mouse and there selecting the layout works.  How do I get the keyboard shortcut working again?

I recently upgraded to Ubuntu 13.10, with the new keyboard handling system. The little "switch keyboard" option does not let me set it to Alt+Shift. How can I get this keyboard binding, as I have absolutely no interest in using the Mac-esque Super+Space combo?


Why don't we define $\frac 10$ as $j$ , $\frac 20$ as $2j$ , and so on? I know that by following the rules of math this eventually leads to $1=2$ , but we could make an exception and say that $j$ is the only number such that $0*j \not= 0$ , and put other restrictions necesary so that we don't get contradictions. We do this for $i$ , so why can't we do it here? For example, $i^2$ , is defined as $-1$ , but you could also say $i^2=\sqrt {-1} *\sqrt {-1}=\sqrt {(-1)(-1)}=\sqrt{1}=1$ , but we make an exception for this.

Before, the concept of imaginary numbers, the number $i = \sqrt{-1}$ was shown to have no solution among the numbers that we had. So we declared $i$ to be a new type of number. How come we don't do the same for other "impossible" equations, such as $x = x + 1$, or $x = 1/0$?  Edit: OK, a lot of people have said that a number $x$ such that $x = x + 1$ would break the rule that $0 \neq 1$. However, let's look at the extension from whole numbers to include negative numbers (yes, I said that I wasn't going to include this) by defining $-1$ to be the number such that $-1 + 1 = 0$. Note that this breaks the "rule" that "if $x \leq y$, then $ax \leq ay$", which was true for all $a, x, y$ before the introduction of negative numbers. So I'm not convinced that "That would break some obvious truth about all numbers" is necessarily an argument against this sort of thing.


How would you go about finding out how much memory is being used by an object? I know it is possible to find out how much is used by a block of code, but not by an instantiated object (anytime during its life), which is what I want.

I want to know how to get size of objects like a string, integer, etc. in Python.  Related question:   I am using an XML file which contains size fields that specify the size of value. I must parse this XML and do my coding. When I want to change the value of a particular field, I will check the size field of that value. Here I want to compare whether the new value that I'm gong to enter is of the same size as in XML. I need to check the size of new value. In case of a string I can say its the length. But in case of int, float, etc. I am confused.


Having a terrible time trying to get react to render my page correctly  I have this  ReactDOM.render(     <React.StrictMode>         <Provider store={store}>             <Router />         </Provider>     </React.StrictMode>,     document.getElementById('root'), )   in my index.html I have  html, body, #root, #root>div {   height: 100%;   overflow: hidden; }   inside router I have              <>                 <GlobalStyle />                 <Nav/>                 <div>                     <Router>                         <Route component={Home} path="/" />                     </Router>                 </div>             </>   I want to display my nav on the top and then the components underneath to take up the rest of the screen space but NOT overflow and render a scroll. but whatever I try and do anything I cant seem to display both  I've tried adding a fixed height to the nav bar. height: 100px !important which works well for the navbar but then the rest of the content is about 60% of the page and there is an annoying div called. <div tabindex="-1" style="outline: none"> which doesn't appear in my code anywhere. I think an accessibility thing? but when I set that to 100% and my container div below it to 100%, then it seems to work. however I cant set that to be 100% in my code so I'm left confused  I also assumed the code I set in the html would cascade down, so I'm confused why it's not cascading to this div? I wonder if setting the navbar is causing this?  anyway, all I want is a page that takes up the whole screen. but also renders a nav bar for 100px or so  any ideas?

I am working on a web application where I want the content to fill the height of the entire screen.  The page has a header, which contains a logo, and account information. This could be an arbitrary height. I want the content div to fill the rest of the page to the bottom.  I have a header div and a content div. At the moment I am using a table for the layout like so:  CSS and HTML    #page {     height: 100%; width: 100% }  #tdcontent {     height: 100%; }  #content {     overflow: auto; /* or overflow: hidden; */ }

...

...

     The entire height of the page is filled, and no scrolling is required.  For anything inside the content div, setting top: 0; will put it right underneath the header. Sometimes the content will be a real table, with its height set to 100%. Putting header inside content will not allow this to work.  Is there a way to achieve the same effect without using the table?  Update:  Elements inside the content div will have heights set to percentages as well. So something at 100% inside the div will fill it to the bottom. As will two elements at 50%.  Update 2:  For instance, if the header takes up 20% of the screen's height, a table specified at 50% inside #content would take up 40% of the screen space. So far, wrapping the entire thing in a table is the only thing that works.


I'm working on implementation of keccak algorithm and have one problem. Tell me please, takeing an example "test": will state (before block permutations, but after padding - pad10*1) look like this:  {80...0 0 0 0 0} {0 0 0 174736574 0} {0 0 0 0 0} {0 0 0 0 0} {0 0 0 0 0}  or maybe like this:  {80...0 0 0 0 0} {0 0 0 0 0} {0 0 0 0 0} {0 174736574 0 0 0} {0 0 0 0 0}  assuming that padded "test" look like this: 0x0000000174736574, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x8000000000000000,  I mean: 174736574 will be on A[1,3] or A[3,1] or somwhere elese?  It's hard for me to understand, because i implemented all functions. I checked all functions - they work properly. But my hash is still different that proper hash calculated on the websites. I suppose that mistake is in absorbing phase. I will be gratefull for answer.  And if i am wrong, how properly put data into the state?

I am trying to implement Keccak in Java for my school work. And I am getting stuck in two places:   On the  the padding is shown as      P = M || 0x01 || 0x00 || … || 0x00   P = P xor (0x00 || … || 0x00 || 0x80)   However on the  section 1.1.2 they mention the variable rate padding as 10*1.   The way I read it, to prepare message for absorption phase, you cut your message into pieces of size r (bit rate). To get message length multiple of r you would append or concatenate the message with just, (for simplicity I am considering just bytes) in case just 1 byte padding required it will be 0x81. And if more than one byte required then it would be 0x80...0x01. So my padding implementation would be something like      P = M || 0x80...01    Where am I reading the specification in wrong way?  How is the placement of the bits in the state? I mean if I have a message of say 2 bits, then my bit goes to state position S[0][0][0], but then where should I place the next bit in the same row that is S[0][1][0] or in the same lane that is S[0][0][1]. I would have assumed to go with placing the bit in next cell in the row, and then when you are finished with bits from one slice, then you again start with [0][0] position in next slice. But the way most of the functions are defined with respect to slices, makes me think, it could be other way around. I am unable to find in specification, where they clearly mention this.   Please just point me to places in specification which can resolve my confusion. Thanks.


I want to prove that for each real number $x>0$, the statement  $${\left(\frac{x+1 } {2}\right)}^{\!x+1} \leq x^x$$  is correct.   I’ve tried using mathematical induction methods, but haven’t found a solution. Although, using any method is appreciated.


I need some guidance regarding how I can make sure of the quality of that product.

I have little experience with testing and I'm being hired to work on a team where I am the only tester. I'm struggling to find the best approach for the process. Being alone should I write down a test script or not? Wouldn't it take too much time? I have no experience in writing test scripts, could anyone help with a good reference (book, video or whatever), please?


I want to run an unmodified MS Windows application, distributed across multiple machines. Can I extend its Symmetric Multiprocessing support to span multiple CPUs on multiple machines? Instead of just a single machine.

by now I have 10 servers for hpc, power computing oriented. My users need to launch several processes using qmake. The users are used to work with ubuntu 9.10, and the software from the repositories is switable for them.  I've deployed ubuntu 9.10 to all 10 servers (pxe rocks).  By now we work with parallel-ssh and cluster-ssh, which allows as to launch the same process to all servers. With this tools this tools the servers remain as independent but with the same software and the same launched command.  Now we would like to go to next step and see all the servers as a single one with all the resources from the other 9 as if was its resources.   The difference would be substantial in time to process and also time to design the command to launch.  Any advice on wich software to use will be very useful?  Thanks


I have a dataset containing some hundreds of thousands of observations, out of which some small number contain an event of interest x. Let's say that my total dataset is large enough that I have a decent confidence in the overall frequency of x.  But what I'm really interested in is the frequency of x together with some other condition y, and the frequency of y in the dataset is much lower. The total number of observations of y doesn't give me enough data to make a confident prediction about how well it correlates with x, and the actual number of observations of x+y is often zero, even though the theoretical frequency of x+y must be something larger than zero.  So how can I estimate the true probability of x+y, given the overall frequency of x in the data set and the small-ish number of instances of y that I have?  Edit: I know that x and y are not independent, but at the outset I don't know anything about the nature of the relationship between them. The entire point of the exercise is to determine whether they have a positive or negative correlation.  Sorry, I know next to nothing about statistics and I don't know what the proper terminology is to describe this situation.

I was wondering if there is a way to tell the probability of something failing (a product) if we have 100,000 products in the field for 1 year and with no failures? What is the probability that one of the next 10,000 products sold fail?


I often find myself in the situation that I browse the SE sites using my mobile browser (since I find it easier to keep multiple sites and questions open the same time) and then want the edit or answer a question.  I think the editor of the iOS app is much better then the mobile website experience, to I had like to open the question in the app to do the things I want to.  So I propose to create an open in app button on the mobile website, or another (easy) option to open a question in the app.

Can we add functionality to the mobile site to view the page in the SE iOS app? It could be through  or a link at the bottom where the download link is.        I really don't care which, but right now there's just no way to do it.


What's the correct way of saying it?   "X book is available at Amazon" or "X book is available on Amazon?"

How should I phrase it:     This question has been asked at Stack Overflow.   Or,     This question has been asked on Stack Overflow.


I have two list a =[72,82,955,55,.....] and b=[5,7,8...] I want to remove the element from a. list b specifies the indexes from where elements to be removed.

Is it possible to delete multiple elements from a list at the same time? If I want to delete elements at index 0 and 2, and try something like del somelist[0], followed by del somelist[2], the second statement will actually delete somelist[3].  I suppose I could always delete the higher numbered elements first but I'm hoping there is a better way.


For each natural number $n\in\mathbb{N_0}$ list all the sets with at most $n$ elements and with maximal element as and including $n$, in numerical order. Now all the elements of $P(N)$ will be listed as n gets larger. Label each set of natural numbers with another natural number. Why is the above not a 1:1 correlation between N and P(N)? The sequence starts with the empty set, then $\{1\}, \{2\}, \{1,2\}, \{3\}, \{1,3\}, \{2,3\}, \{1,2,3\}, \{4\}, \{1,4\}, \{2,4\}, \{3,4\}, \{1,2,4\}, \{1,3,4\}, \{2,3,4\}, \{1,2,3,4\}$ …

I am confused as to how Cantor's Theorem and the Schroder-Bernstein Theorem interact. I think I understand the proofs for both theorems, and I agree with both of them. My problem is that I think you can use the Schroder-Bernstein Theorem to disprove Cantor's Theorem. I think I must be doing something wrong, but I can't figure out what. Can someone tell me where I am going wrong? Here's how I think I can prove that the set of all natural numbers has the same cardinality as its power set. Cantor's Theorem says that the power set of any set A has greater cardinality than A. Specifically, the set of all natural numbers, $\mathbb{N}$, is countably infinite, while its power set $P(\mathbb{N})$ is uncountably infinite. The Schroder-Bernstein Theorem says that, for two sets $A$ and $B$, if there exist one-to-one functions $f:A\mapsto B$ and $g:B \mapsto A$, then sets $A$ and $B$ have the same cardinality. I will try to use this to prove that the set of all natural numbers N has the same cardinality as its power set $P(\mathbb{N})$.  I need to prove that there exist one-to-one functions $f:\mathbb{N}\mapsto P(\mathbb{N})$ and $g:P(\mathbb{N})\mapsto \mathbb{N} $   $f:\mathbb{N}\mapsto P(\mathbb{N})$   Define $f:\mathbb{N}\mapsto P(\mathbb{N})$, $n\mapsto f(n)=\{n\}$  For each output $f(n)$, there can only be one n corresponding to $f(n)$, so $f$ is a one-to-one function.   $g:P(\mathbb{N})\mapsto \mathbb{N} $   Define $g:P(\mathbb{N})\mapsto \mathbb{N} $ as follows  Each element of $P(\mathbb{N})$ is a subset of $\mathbb{N}$, as represented by $\{{a}_{1},{a}_{2},\dots ,{a}_{k}\}$ where ${a}_{1},{a}_{2},\dots ,{a}_{k}$ are elements of $\mathbb{N}$  For each element $s=\{{a}_{1},{a}_{2},\dots ,{a}_{k}\}$ of $P(\mathbb{N})$, the elements of $s=\{{a}_{1},{a}_{2},\dots ,{a}_{k}\}$ are ordered from lowest to highest, so that ${a}_{1}<{a}_{2}<\dots <{a}_{k}$. The order of a set does not matter, so this can be done without creating a new set.  For each element $s=\{{a}_{1},{a}_{2},\dots ,{a}_{k}\}$ of  $P(\mathbb{N})$, $g(s)={{p}_{1}}^{{a}_{1}} *{{p}_{2}}^{{a}_{2}} * ... * {{p}_{k}}^{{a}_{k}}$, where ${p}_{1},{p}_{2},...,{p}_{k}$ are each the $k$th prime number. Ex. ${p}_{1}=2, {p}_{2}=3, {p}_{3}=5,\dots$  $P(\mathbb{N})$ contains the empty set, so $g(\emptyset)=0.$  The set of all prime numbers is countably infinite, so it has the same cardinality as the largest element of $P(\mathbb{N})$, which is $\mathbb{N}$.  Each output $g(s)$ is the prime factorization of some number n. Each number n has a unique prime factorization, so there is only one s in  $P(\mathbb{N})$ whose $g(s)$ is the prime factorization of n.  Since the elements of $s=\{{a}_{1},{a}_{2},\dots ,{a}_{k}\}$ are ordered from lowest to highest, ${a}_{1}$ is the only element of $s$ that can be $0$. Thus, ${p}_{1}=2$ is the only prime number that can have an exponent of 0 in the output. Thus, it is impossible for any set $s$ in  $P(\mathbb{N})$ to have the same output $g(s)$ as a set of different length in $P(\mathbb{N})$ . In other words, it is impossible to add or remove an element of s to create a new set ${s}_{2}$ so that $g(s)=g({s}_{2})$.  Every element $s$ of  $P(\mathbb{N})$ has a unique output $g(s)$, so $g:P(\mathbb{N})\mapsto \mathbb{N} $ is a one-to-one function.  So $f:\mathbb{N}\mapsto P(\mathbb{N})$ and $g:P(\mathbb{N})\mapsto \mathbb{N} $ are both one-to-one functions.  So $\mathbb{N}$ and  $P(\mathbb{N})$ have the same cardinality.  I'm fairly certain that both Cantor's Theorem and the Schroder-Bernstein Theorem are correct, so where does my proof go wrong?


I've just learned about the Heartbleed Bug (OpenSSL leaking private keys), and based on the website, heartbleed.com, it says that OpenSSL 1.0.1 through version f is affected. However it leaves off Ubuntu 13.04 off the affected list AND the repositories do not have an update to it.  Let me paste some information here:  demortes@vps:/$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description:    Ubuntu 13.04 Release:        13.04 Codename:       raring   AND  demortes@vps:/$ openssl OpenSSL> version OpenSSL 1.0.1c 10 May 2012 OpenSSL>   I'm seeing that we're not affected even though I have 1.0.1c installed... is this accurate. If not, how can I install OpenSSL 1.0.1g with package management now? If it is accurate... why?

As of today, a  has been found affecting versions 1.0.1 through 1.0.1f (inclusive) and 1.0.2-beta.  Since Ubuntu 12.04, we are all vulnerable to this bug. In order to patch this vulnerability, affected users should update to OpenSSL 1.0.1g.  How can every affected user apply this update now?


I want to take a string from stdin but I don't want a static array of fixed size  I know that scanf need something where save the stdin input, but I can't do something like this:  char string[10] scanf("%s",string);   becouse I need to know before how long will be the string in order to allocate the right memory space.  Can you help me to resolve this problem?    woooooooo   i'm still locked with this problem... I'm going mad  can you please give me the working code?

What is the simplest way to read a full line in a C console program The text entered might have a variable length and we can't make any assumption about its content.


I have an exercise that states:  Suppose that $f:\mathbb{N}\rightarrow\mathbb{R}$. If $\lim_{n\rightarrow\infty}f(n+1)-f(n)=L$, prove that $\lim_{n\rightarrow\infty}f(n)/n$ exists and equals $L$.  I have wracked my brain over this exercise for about 5 hours now and really have not gotten ANYWHERE with it...does anyone have a suggestion on how begin proving this?  Thank you.

Here's the problem in full. I've stared at it for hours and can't get anywhere, so a hint would be nice.  Suppose that $f:\mathbb N\rightarrow\mathbb R$. If $$\lim_{n\rightarrow\infty}f(n+1)-f(n) = L$$ prove that $\lim_{n\rightarrow\infty}f(n)/n$ exists and equals $L$.  This problem is marked with the word "Cauchy", so I'm guessing Cauchy sequences or something related to them will be necessary, but I can't figure out what.  Edit: It appears as if the Stolz-Cesaro Theorem makes this quite easy. Unfortunately though, we have not discussed this, so I won't be able to use this.


I create an animation like this:  private DoubleAnimation BusyGettingNewOrders = new DoubleAnimation(40, TimeSpan.FromSeconds(1));   And start it with this.  BusyGettingNewOrders.RepeatBehavior = new RepeatBehavior(1000); BusyGettingNewOrders.To = 40; BusyGettingNewOrders.Duration = TimeSpan.FromSeconds(1); GetNewOrdersImage.BeginAnimation(Button.WidthProperty, BusyGettingNewOrders);   I need to stop it after a long running process ends.  I tried the following, but although it executes, it has no effect.  The animation continues to run.  BusyGettingNewOrders.RepeatBehavior = new RepeatBehavior(1);   Ideas?

I have something like this:   barProgress.BeginAnimation(RangeBase.ValueProperty, new DoubleAnimation(     barProgress.Value, dNextProgressValue,     new Duration(TimeSpan.FromSeconds(dDuration)));   Now, how would you stop that animation (the DoubleAnimation)? The reason I want to do this, is because I would like to start new animations (this seems to work, but it's hard to tell) and eventually stop the last animation...


Why do we say that a system with mass gap has correlation function which decays exponentially and one without a mass gap has a slower power law decay?

I've read some papers recently that talk about gapped Hamiltonians or gapless systems, but what does it mean?  Edit: Is an XX spin chain in a magnetic field gapped? Why or why not?


I bought a Dell Inspiron 3552 that came preinstalled with windows 10, it's 64-bit.  The problem is that I hate windows and would love to try Ubuntu however the installer won't boot, tried launching it as a live USB but it won't boot up.  Help?

How do I make an Bootable Ubuntu USB containing the the latest version of Ubuntu?  For completeness, how would I be able to do this on Ubuntu, Windows, OS X or another Linux distro?


:  Suppose the pdf of $(X_1,X_2,X_3,X_4)$ is given by $$f(x_1,x_2,x_3,x_4)=\begin{cases}\text{constant}&,\text{ if }x_1^2+x_2^2+x_3^2+x_4^2\le 1 \\ 0&,\text{ otherwise}\end{cases}$$ Find the covariance between $X_1$ and $X_4$. Are $X_1$ and $X_4$ independent? Justify your answer.  I was solving some question papers and got stuck in this problem. My problem: I know how to find "marginal probabilities" from a joint probability density function and also know how to find the covariance and independence. But I am getting stuck in the range part while integration. While finding f(x1, x4) or f(x1) or during finding the covariance how do I integrate over the given range as I am not accustomed to handle such ranges as in here.(marked in red)  Please help me solve this. Thank you.

CONTEXT  In my research, I am utilizing an $n$-ball distributions along with two related distributions. I'd like to make certain I have a firm handle on the way to describe my three distributions. I have been looking for reference books on the subject [1], I've got some guidance, but have not been able to find what I'm looking for yet.   In this post, I attempt to deal with the simplest case that i am concerned with. I'm modelling my approach to this based on the format I find on wikipedia (e.g. [2])  QUESTIONS   What is the characteristic function of the uniform distribution on a ball in $\mathbb{R}^𝑛$? [edit: solution offered by @whuber in the below solution.]  What is the entropy of the uniform distribution on a ball in $\mathbb{R}^𝑛$? [edit: solution offered by @whuber in the below comment.]  MY UNDERSTANDING  The $n$-ball distribution here is a generalization of the uniform distribution.   Parameters  By $n\in \mathbb{N}$ I denote  the dimension of the ball.  By $R\in \mathbb{R}, R>0$ I denote the radius of the $n$-ball.  By $\gamma$ I denote a parametrization of the $n$-ball given as $\gamma: (0,R) \times  \left[0, \pi\right) \times \cdots \times  \left[0, \pi\right)  \times \left[0, 2\pi\right) \rightarrow \mathbb{R}^n$, which is defined by: $$\gamma\begin{pmatrix}r\\\\ \phi_1 \\\\ \vdots \\\\ \phi_{n-1}\end{pmatrix} \rightarrow   \begin{bmatrix}    r \cos{(\phi_{1})} \prod\limits_{i=1}^{1-1} \sin{(\phi_{i })} \\\\   r \cos{(\phi_{2})} \prod\limits_{i=1}^{2-1} \sin{(\phi_{i })} \\\\   \vdots \\\\   r   \cos{(\phi_{n-1 })} \prod\limits_{i=1}^{n-1-1}   \sin{(\phi_{i })} \\\\   r   \prod\limits_{i=1}^{n-1}   \sin{(\phi_{i })} \end{bmatrix}. $$  Support $$i = {1, 2, \ldots, n}$$ $$x_i = (-R,R)$$ $$0\leq \sum_{i=1}^{n}x_i^2 < R^2$$  Probability Density Function  With respect to the indicator for the $n$-ball, $\mathcal{I}(\left\|\textbf{x}\right\|_2 <R)$, the probability density is $$\frac{\Gamma\left(\frac{n}{2} + 1\right)}{\pi^\frac{n}{2} R^n}\,\mathcal{I}(\left\|\textbf{x}\right\|_2 <R)$$  Mean  $$E(X_i) = 0$$  Variance  $$\textrm{Var}(X_i) = \dfrac{1}{n+2} R^2$$  $$\textrm{Cov}(X_i,X_j) = 0\quad\quad i \neq j$$  Entropy  $$\log\left(\frac{\Gamma\left(\frac{n}{2} + 1\right)}{\pi^\frac{n}{2} R^n}\right)$$  Characteristic function  $$\phi_n(t) = e^{-i\frac{|t|}{R}} \,_1F_1\left(\frac{n+1}{2};n+1; i\frac{2|t|}{R}\right).$$  BIBLIOGRAPHY  [1]   [2]


I have a friend who lives in Atlanta, Georgia. There is a guy she met on Facebook who stays in Malaysia but originally from Nigeria.  This guy asked to send her money and open lots of accounts, transfer the money, withdraw it and pay it to these guys. She is promised to get a percentage from the transactions.  Is this a scam?

This girl that I'm friends with and have actually seen in person before, keeps posting [on social media] that she "loves when the transfer goes through" and gets $2000-$6000 for free quite often. She said you can make up to $6500 a day. She is not very smart and barely spells correctly. She keeps saying that all she is doing is "transfers" and that's it. So many of my friends are feeding into this crap. So I asked her what it is. She basically said "it's legit" and asked me for my bank username and password so she could see how much money to deposit into my account. I said no way and left it at that. She also said she is not stealing or doing anything illegal. She is getting her friends free money and I think they're naive. What is she actually doing? Is it illegal? I am sure she is incapable of doing crazy money wiring to different countries.   Thank you everyone for answering my question. I am not stupid, I did not give her my information. I knew she was up to something illegal, so thank you for giving me some input on what exactly she is doing. I submitted an anonymous tip to my local sheriff's department. I'm hoping they see it and pursue it, or forward it to the right authorities I.e the FBI or something.


Found this problem on the most recent GRE practice booklet by ets. I ended up skipping it because it looked like too much work. Going back through, I still don't know how to evaluate it.   To me, this is the obvious first step to make.  $\int_{-\frac{\pi}{4}}^{\frac{\pi}{4}} \cos(t)+\sqrt{1+t^2} \cos^3(t)\sin^3(t) dt \\ =\int_{-\frac{\pi}{4}}^{\frac{\pi}{4}} \cos(t) dt +\int_{-\frac{\pi}{4}}^{\frac{\pi}{4}} \sqrt{1+t^2} \cos^3(t)\sin^3(t) dt \\ =\sqrt{2}+\int_{-\frac{\pi}{4}}^{\frac{\pi}{4}} \sqrt{1+t^2} \cos^3(t)\sin^3(t) dt $  Having taken a few practice test, I have a gut feeling that the integral that remains will vanish, especially since the integral is over $[-\frac{\pi}{4},\frac{\pi}{4}]$, however I'm not sure how to show that this is indeed true. Is there an easy/quick way to reason through this?

Evaluate: $$\int_{-\pi/4}^{\pi/4}(\cos(t)+\sqrt{1+t^2}\cos(t)^3\sin(t)^3)dt$$  I have tried substituting $t=\tan(\theta)$ and breaking up the $\cos(t)^3$ using $\cos(t)^2=1-\sin(t)^2$, but I can't figure it out.  This question is #21 from the Math subject GRE form GR1268.


I have the below code and I would expect it to throw a ConcurrentModificationException, but it runs successfully. Why does this happen?  public void fun(){     List <Integer>lis = new ArrayList<Integer>();     lis.add(1);     lis.add(2);      for(Integer st:lis){         lis.remove(1);         System.out.println(lis.size());     } }  public static void main(String[] args) {     test t = new test();     t.fun(); }

I am using a Collection (a HashMap used indirectly by the JPA, it so happens), but apparently randomly the code throws a ConcurrentModificationException. What is causing it and how do I fix this problem? By using some synchronization, perhaps?  Here is the full stack-trace:  Exception in thread "pool-1-thread-1" java.util.ConcurrentModificationException         at java.util.HashMap$HashIterator.nextEntry(Unknown Source)         at java.util.HashMap$ValueIterator.next(Unknown Source)         at org.hibernate.collection.AbstractPersistentCollection$IteratorProxy.next(AbstractPersistentCollection.java:555)         at org.hibernate.engine.Cascade.cascadeCollectionElements(Cascade.java:296)         at org.hibernate.engine.Cascade.cascadeCollection(Cascade.java:242)         at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java:219)         at org.hibernate.engine.Cascade.cascadeProperty(Cascade.java:169)         at org.hibernate.engine.Cascade.cascade(Cascade.java:130)


I'm using an approved browsers like Chrome and Safari. But in the human verification page, the Captcha box is not displaying for me.  What should I do?

I'm not able to answer a question on Stack Overflow because the Human Verification page is showing up but without any CAPTCHA. I found many questions relating this but without a solution that worked for me. I guess this has something to do with my No-Script settings (Firefox plug-in). I selected "Temporarily allow all this page" several times but without success. I don't know of any proxy related restrictions on my internet connection but anyhow I there were some, I couldn't change them. Does this mean I can't pass the "Human verification"?


In the following sentence     The hippocampus plays an important role in the formation of emotion   and memory consolidation.   my teacher pointed out that article The in front of the word hippocampus is incorrect, and A should be used instead. As in     A hippocampus plays an important role in the formation of emotion   and memory consolidation.   I disagree. Who do you think is right?

I know that the definite article "the" can be used to mean a generic idea of something as in "the lion is the king of the animals." In this sentence, the in "the lion" is used to imply the general image of lions, so not specifying a particular lion.   However, I am confused in identifying where a "the" in a sentence is used for a general idea or a specific reference. For example, in the sentence "the price of gas is soaring", I heard that "the" in the sentence is an example of the generic use of the. Although I can easily understand the generic use of "the" in the lion example, but I do not understand how there is an general idea about gas price. Soaring gas price is something real,and gas prices in different regions( in a hypothetical situation) can be different. So, if I say "the price of gas is soaring", do I mean the price of gas that is determined by the world's oil system or can I say "the gas price" even when I am indicating the state of gas price in "a particular region"?    I know it is even difficult to understand my question, but I hope someone could find what I am confused about and give an answer.


My question is "how to center a span class on button?". See this, arrow-up is behaving in it's own way and not at the center of button. If the code works correctly, An equilateral trinagle will appear in the left of button following with the words Go back to top. And my code has errors which is limiting that to appear in the above mentioned manner. This is running example,    .arrow-up {   width: 0;   height: 0;   border-left: 5px solid transparent;   border-right: 5px solid transparent;   border-bottom: 5px solid #101010; } <button>Go back to top</button>

I have a div with two images and an h1. All of them need to be vertically aligned within the div, next to each other. One of the images needs to be absolute positioned within the div. What is the CSS needed for this to work on all common browsers?

testing...


I am designing a tabular table (row/cell) containing 40 rows, 10 cells per row.  A requirement is that the rows be 7mm in height and cells 17mm in width.  The width I seem to have found.  I have not found a method (so far) to set an absolute/fixed row height.  Does such a mechanism exist, and if so, a pointer to the documentation would be most appreciated.   rob

I'm trying to create a multi-page table with all cells having the same height (as well as certain fixed widths) so that certain manual cut-and-paste operations are a lot easier.  One issue is that one column in particular is text-heavy and should line-break within the cell.  As I don't want it justified, I looked into alternatives such as .  This is doing exactly what I want for horizontal alignment.  For vertical alignment, I've looked at  and the \vphantom method detailed in the above link doesn't seem to be working.  Here's what I'm currently working with:  \documentclass[11pt]{article} \usepackage{array}  \newcolumntype{P}[1]{>{\raggedright\hspace{0pt}\arraybackslash}p{#1}} \def\Z{\vphantom{\parbox[c]{1.7in}{\Huge Something Long}}}  \begin{document} \begin{tabular}{| c || P{0.5in} || P{0.5in} || P{5in} |}\hline  1.  \Z &&& Long long long long long long long long long             long long long long long long long text  \\\hline 2.  \Z &&& More long long long long long long long long             long long long long long long long text  \\\hline \end{tabular}   When I compile, the cells do not have a uniform height, and none of them are as large as 1.7 inches vertically.  So this suggests that somehow the \vphantom method is failing.  Does anybody know of a relatively straightforward solution to this problem?


I have a Python script in which I get the BMesh from an existing mesh. Then I want to get the outer edges of the mesh, not the inner edges, mesh could for instance look like this:  I want to get the edges as a sequence that are not in the inside. Thx for your help. Edit: Can get the outer edges now like that: bm = bmesh.from_edit_mesh(obj.data)  outer_edges = [edge for edge in bm.edges if edge.is_boundary]  for edge in outer_edges:     vertices.append(edge.verts[0])  The only problem I have now is that I want to order them clockwise, any idea for this? Edit 06.11.2020: Ok ended up with this one here: bm = bmesh.from_edit_mesh(obj.data) bm.verts.ensure_lookup_table()  vert = bm.verts[0] prev = None  for i in range(len(bm.verts)):     next = None     for v in [e.other_vert(vert) for e in vert.link_edges if e.is_boundary]:         if (v != prev):             next = v      vertices.append(obj.matrix_world @ vert.co)      if next == None:         break          prev, vert = vert, next

I would like to select in python the visible perimeter of a mesh. My idea is to get only the external vertices, not all visible.   Any idea or link that can help me?


I am little bit confuse to use Where I was or Where was I.  For Example I use -     My brother wanted to know where was I?   Please help

I have always followed the former rule, i.e, "Tell me why I should marry you" (without a question mark). But my cousin insists the latter is correct. He seems equally confident that he is correct. So can you please answer which is correct? Or are both correct?  Or the following example would illustrate my question better:        Give me reasons why I should marry you.   Give me reasons why should I marry you?      Which of the above is correct?


\footnote[1]{\nameref*{8.1.16} is an अधिकार सूत्र it goes upto \nameref*{8.3.55}} \& अङ्गाधिकार (अङ्गस्य)\footnote[2]{\nameref*{6.4.1} is an अधिकार सूत्र it goes upto \nameref*{7.4.97}}  I am using footnote as shown above. However the footnote appears to be floating and when I don't have much in the page it appears in the middle of the page. I got by so far with \vspace{} but I think there must be a way to position this at the bottom of the page despite whats in the page. Thanks for your help

This is the document:  \documentclass[12pt]{article} \usepackage[top=3in, bottom=3in, left=3in, right=3in]{geometry} \usepackage{lipsum} \interlinepenalty=10000 \begin{document} This is first short par\footnote{foot note}  \lipsum[1] \end{document}   As you can see the foot note is "glued" to the text and is not a "foot" note any more.. How can I make drop it down to the bottom of the page, where it will look like a real foot note?


I've been reading Naruto, and I've noticed Kurenai's eyes are weird. They look a bit like Sharingan eyes, but there has never been indication they they are at all actually related to the Sharingan. Has there been any explanation for her eyes?

Since the start of the series, after the Sharingan and Byakugan had been revealed, Kurenai's eyes seem kind of different from normal eyes and more like the Doujutsu.    During the attack of the Nine-Tailed Fox on Konoha, her father appeared for the first time in the story. He too possessed similar patterns in his eyes.  So is it some kind of Doujutsu, do her eyes have special abilities similar to the Sharingan or Byakugan, etc.?


I have a file app.spec with the string:  Version:  1.0.0   I want to replace 1.0.0 with the variable version e.g. 1.0.1.  The regex below which matches this but how can I replace only the first occurrence?  sed -i -E "s/[0-9]+\.[0-9]+\.[0-9]+/$version/" ./app.spec  I tried but it didn't work.  sed -i -E "0,/[0-9]+\.[0-9]+\.[0-9]+/$version/" ./app.spec

I would like to update a large number of C++ source files with an extra include directive before any existing #includes. For this sort of task, I normally use a small bash script with sed to re-write the file.   How do I get sed to replace just the first occurrence of a string in a file rather than replacing every occurrence?  If I use  sed s/#include/#include "newfile.h"\n#include/   it replaces all #includes.   Alternative suggestions to achieve the same thing are also welcome.


I can't figure out what's wrong with my code but it fails at deletion of PS in the following [null, null, null, PS]   /**  * Removes the specified string from this hash table       * (if the string is in this table).      */ public void delete(String s) {     // TODO     int k = 0;     for (int i=0;i<M;i++) {         if (keys[i] != null) {             if (keys[i] == s) {                  k = i;         }         }     }     keys[k] = null;     for (int i=k;i<M;i++) {         if (keys[i+1]!=null) {             keys[i] = keys[i+1];         }     }     N--;       // halves size of array if it's 12.5% full or less     if (N > 0 && N <= M/8) resize(M/2); }

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?


I've noticed that when you flip the base and the exponent in $2^4$ to get $4^2$, you get the same value, $16$.  If there are any other numbers that can make this work, let me know.  This is just mind-blown for me!  Are there any other numbers that work?  I used to do this and ta-daaaaaaah!

We know that $2^4 = 4^2$ and $(-2)^{-4} = (-4)^{-2}$. Is there another pair of integers $x, y$ ($x\neq y$) which satisfies the equality $x^y = y^x$?


I am writing a script to kill a job which runs more than 30 minutes. My epoch time format is like 1503935475067 and I am using current_time_stamp=`date +%s%3N`  How to find difference between two epoch time stamps?

I am creating a simple backup script. I would like to have a message saying "You last backed up x days ago" on login. I can create a file when I do the backup "backup/.last_backup_timestamp" but what format should I use and how would I find the difference in days between then and now in bash?  Thank-you


I am having trouble getting bibtex to cite properly.   I am fairly new to LaTeX so please forgive me for any ignorance.  I am using Texmaker to utilise LaTeX.  Here is my code:  \documentclass[12pt]{report} \usepackage{biblatex} \addbibresource{test.bib}  \begin{document}  hello \cite{AAA}  \printbibliography \end{document}   Bibliography code  @book{AAA, title = {apples and oranges}, author = {Fruit Shop}, year = {2000}, publisher={fruit}   Interestingly, the $\addbibresource$ is marked in bold blue font? Why is this?  The output is    I have tried running the document in the sequence:  quickbuild  BibTeX  quickbuild  quickbuild    But this does not seem to help.  Please help!

Running the minimal example  \documentclass{article} \usepackage{filecontents} \begin{filecontents*}{\jobname.bib} @ARTICLE{example,   author  = {Other, Anthony Norman},   title   = {Some things I did},   year    = {2014},   journal = {J.~Irrep. Res.},   volume  = {1},   number  = {1},   pages   = {1-10} } \end{filecontents*} \usepackage[backend=biber]{biblatex} \addbibresource{\jobname.bib} \begin{document} Hello\cite{example}. \printbibliography \end{document}   I get the warning There were undefined references.  I have read  and know that I need to run:   LaTeX Biber LaTeX   However, my editor is only set up to run BibTeX. How do I go about setting up my editor/IDE to be able to run Biber, and how do I run the LaTeX/Biber/LaTeX cycle?  Answers (sorted alphabetically by editor name)                    Answer guidelines   Each answer should be for one editor. If the editor is cross-platform, if possible give a single answer with notes covering the minor platform variations. Please edit the question to include new answers in the 'link list' Each answer should be 'stand alone', i.e. don't say 'It's almost the same as editor Y but ...' for the editor part Instructions for 'build tools' such as arara or latexmk are welcome but should explain how to set up the editor in question as not all editors allow simple addition of arbitrary tools


console.log(10209761399365907);     Why does this code output a number greater by one (10209761399365908 instead of 10209761399365907)?  This is happening only for this specific number. For instance with 10155071933693662 I get the correct value (10155071933693662).   Is there something I need to know about that specific number? The only workaround I figured out is to pass the value as a string.

Is this defined by the language? Is there a defined maximum? Is it different in different browsers?


Can somebody please explain how an initialization vector works.  My current understanding is that it is used to prevent 2 of the same messages looking identical after encryption, but isn't this the same as what a salt does?  How is it different from a salt?

What are the main differences between a nonce, a key and an IV? Without any doubt the key should be kept secret. But what about the nonce and the IV? What's the main difference between them and their purposes? Is it only that, in literature and in practice, an IV is being used as "initiator" of a block cipher encryption mode which should be unique? And the same property should hold for a nonce as well, but since it doesn't instantiate something we call it a nonce? I.e: in AES-CTR mode the IV is a nonce+counter. And both are put in plaintext format in the beginning of the ciphertext.