qid int64 1 74.7M | question stringlengths 0 58.3k | date stringlengths 10 10 | metadata list | response_j stringlengths 2 48.3k | response_k stringlengths 2 40.5k |
|---|---|---|---|---|---|
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | >
> Would there be any noteworthy changes at all,
>
>
> just assume humanity suddenly stopped existing today for the purposes of the question
>
>
>
Global Warming would continue for a while, if for no other reason than approximately 2.5% of CO2 is sequestered per annum.
<http://euanmearns.com/the-half-life-of-c... | "Is removing people sufficient to stop global warming?" Good question. Answer is not clear. If we have passed the tipping point for arctic permafrost collapse, arctic ocean being ice free in summer, then we may release huge amounts of methane clathrates.
On top of this while oil has to be pumped, natural gas is often ... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | A millennium is a blink of an eye on a geological scale. But interesting things can happen in a blink of an eye. Even disegarding the changes which may happen as a result of the present climatological instability, small but important modification can occur here and there.
I have no idea of the geographical changes bet... | You mention plate tectonics as a cause of change; there are others
* **Rising sea levels**. [Wikipedia has a map](https://en.wikipedia.org/wiki/Sea_level_rise#/media/File:6m_Sea_Level_Rise.jpg) from NASA about how a 6-meter sea level rise would change the world map. Current predictions seem to be something between 0.3... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | A millennium is a blink of an eye on a geological scale. But interesting things can happen in a blink of an eye. Even disegarding the changes which may happen as a result of the present climatological instability, small but important modification can occur here and there.
I have no idea of the geographical changes bet... | In addition to the previously noted changes due to climate and normal geology, the sudden removal of humans a la Discovery Channel's [Life After People](https://www.history.com/shows/life-after-people) would quickly lead to the breakdown of electrical and mechanical infrastructure, including pumping stations (e.g., the... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | A millennium is a blink of an eye on a geological scale. But interesting things can happen in a blink of an eye. Even disegarding the changes which may happen as a result of the present climatological instability, small but important modification can occur here and there.
I have no idea of the geographical changes bet... | "Is removing people sufficient to stop global warming?" Good question. Answer is not clear. If we have passed the tipping point for arctic permafrost collapse, arctic ocean being ice free in summer, then we may release huge amounts of methane clathrates.
On top of this while oil has to be pumped, natural gas is often ... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | You mention plate tectonics as a cause of change; there are others
* **Rising sea levels**. [Wikipedia has a map](https://en.wikipedia.org/wiki/Sea_level_rise#/media/File:6m_Sea_Level_Rise.jpg) from NASA about how a 6-meter sea level rise would change the world map. Current predictions seem to be something between 0.3... | In addition to the previously noted changes due to climate and normal geology, the sudden removal of humans a la Discovery Channel's [Life After People](https://www.history.com/shows/life-after-people) would quickly lead to the breakdown of electrical and mechanical infrastructure, including pumping stations (e.g., the... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | You mention plate tectonics as a cause of change; there are others
* **Rising sea levels**. [Wikipedia has a map](https://en.wikipedia.org/wiki/Sea_level_rise#/media/File:6m_Sea_Level_Rise.jpg) from NASA about how a 6-meter sea level rise would change the world map. Current predictions seem to be something between 0.3... | "Is removing people sufficient to stop global warming?" Good question. Answer is not clear. If we have passed the tipping point for arctic permafrost collapse, arctic ocean being ice free in summer, then we may release huge amounts of methane clathrates.
On top of this while oil has to be pumped, natural gas is often ... |
107,732 | I've tried researching this question myself, but the only data I can find is over huge timescales, like situations where the continents have reformed back into a Neo-Pangea.
I'm not looking for any real drastic changes in positioning, just relatively minor things like seas disappearing or continents slightly shrinking... | 2018/03/23 | [
"https://worldbuilding.stackexchange.com/questions/107732",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/48871/"
] | In addition to the previously noted changes due to climate and normal geology, the sudden removal of humans a la Discovery Channel's [Life After People](https://www.history.com/shows/life-after-people) would quickly lead to the breakdown of electrical and mechanical infrastructure, including pumping stations (e.g., the... | "Is removing people sufficient to stop global warming?" Good question. Answer is not clear. If we have passed the tipping point for arctic permafrost collapse, arctic ocean being ice free in summer, then we may release huge amounts of methane clathrates.
On top of this while oil has to be pumped, natural gas is often ... |
31,158,335 | I encountered a strange issue. It's Wednesday now, and:
```
DateTime date;
DateTime.TryParseExact(
"Wed", "ddd", null, System.Globalization.DateTimeStyles.None, out date); // true
DateTime.TryParseExact(
"Mon", "ddd", null, System.Globalization.DateTimeStyles.None, out date); // false
```
When I change local ... | 2015/07/01 | [
"https://Stackoverflow.com/questions/31158335",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1632632/"
] | I *suspect* the problem is that you've got a very incomplete date format there. Usually, `DateTime.TryParseExact` will use the current time and date for any fields that aren't specified. Here, you're specifying the day of the week, which isn't really enough information to get to a real date... so I suspect that the tex... | Why not use regex if you are wanting validating part of a date?
<https://dotnetfiddle.net/ieokVz>
```
using System;
using System.Text.RegularExpressions;
public class Program
{
public static void Main()
{
string pattern = "(Mon|Tue|Wed|Thu|Fri|Sat|Sun)";
string[] values = {"Mon","Tue","Wed","Thu","Fri","Sa... |
27,674,464 | I been having problems on my onclick function to another JSP.
I wanted to check whether if the session attribute is the same as **John** or **Mark** from my **display.jsp**, then it will display on **new.jsp** with that name.
I have a **login.jsp** and successfully works on **display.jsp** where it able to displa... | 2014/12/28 | [
"https://Stackoverflow.com/questions/27674464",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3127380/"
] | You will get the session variable like beelow:
```
var firstName='<%= session.getAttribute("name")%>';
``` | I don't think you can access session variable from java script, since it executes on client side, what is the output for this piece of code `session.getAttribute("name")` , Are you getting expected value?
Alternatively you can fallow this link [Access session variables in js](https://stackoverflow.com/questions/691831... |
45,964 | Buddha talks of becoming have a cause, is dependent on something other. Like Lamp's flame and light, shadow and real object, The sun and it's aura, object and mirage.
The dependent origination generates the false 'I' which is nothing but the becoming.
Then can one conclude the cessation of becoming is also carried out... | 2021/10/07 | [
"https://buddhism.stackexchange.com/questions/45964",
"https://buddhism.stackexchange.com",
"https://buddhism.stackexchange.com/users/12115/"
] | Good question, more to the point than your first one, IMO.
Regular samsaric mind is "flat", we see things and we interpret them non-ambiguously as per our ego's convictions.
Buddha's mind is "non-flat", it's not like it doesn't interpret at all, rather it produces a solution space of all possible and plausible interp... | You cannot, not at least until you are enlightened & choose to do so.
What you can do is cease identification with the thought; detach yourself from the one who is doing the thinking. Karma will still play out for you, things happen, situations occur, thoughts arise. You can't really stop this.
The waves still as a c... |
45,964 | Buddha talks of becoming have a cause, is dependent on something other. Like Lamp's flame and light, shadow and real object, The sun and it's aura, object and mirage.
The dependent origination generates the false 'I' which is nothing but the becoming.
Then can one conclude the cessation of becoming is also carried out... | 2021/10/07 | [
"https://buddhism.stackexchange.com/questions/45964",
"https://buddhism.stackexchange.com",
"https://buddhism.stackexchange.com/users/12115/"
] | Good question, more to the point than your first one, IMO.
Regular samsaric mind is "flat", we see things and we interpret them non-ambiguously as per our ego's convictions.
Buddha's mind is "non-flat", it's not like it doesn't interpret at all, rather it produces a solution space of all possible and plausible interp... | >
> How does one accomplish a reality not governed by the mind when thought is required to function?
>
>
>
There is no one who can govern. There are only realities which causing others.
So, the purification of understanding in realities is the only way to specify the using of "govern" word whether wrong or right ... |
45,964 | Buddha talks of becoming have a cause, is dependent on something other. Like Lamp's flame and light, shadow and real object, The sun and it's aura, object and mirage.
The dependent origination generates the false 'I' which is nothing but the becoming.
Then can one conclude the cessation of becoming is also carried out... | 2021/10/07 | [
"https://buddhism.stackexchange.com/questions/45964",
"https://buddhism.stackexchange.com",
"https://buddhism.stackexchange.com/users/12115/"
] | Good question, more to the point than your first one, IMO.
Regular samsaric mind is "flat", we see things and we interpret them non-ambiguously as per our ego's convictions.
Buddha's mind is "non-flat", it's not like it doesn't interpret at all, rather it produces a solution space of all possible and plausible interp... | "governed by the mind" suggest that there is one who is governed. Once you enter the 2nd refuge of the 3 jewels of Buddhism (taking refuge in the Dharma) and the teacher and the teaching as localized sources melt away, you become one with all , therefore the continued teaching and realizations do not flow from a person... |
45,964 | Buddha talks of becoming have a cause, is dependent on something other. Like Lamp's flame and light, shadow and real object, The sun and it's aura, object and mirage.
The dependent origination generates the false 'I' which is nothing but the becoming.
Then can one conclude the cessation of becoming is also carried out... | 2021/10/07 | [
"https://buddhism.stackexchange.com/questions/45964",
"https://buddhism.stackexchange.com",
"https://buddhism.stackexchange.com/users/12115/"
] | >
> How does one accomplish a reality not governed by the mind when thought is required to function?
>
>
>
There is no one who can govern. There are only realities which causing others.
So, the purification of understanding in realities is the only way to specify the using of "govern" word whether wrong or right ... | You cannot, not at least until you are enlightened & choose to do so.
What you can do is cease identification with the thought; detach yourself from the one who is doing the thinking. Karma will still play out for you, things happen, situations occur, thoughts arise. You can't really stop this.
The waves still as a c... |
45,964 | Buddha talks of becoming have a cause, is dependent on something other. Like Lamp's flame and light, shadow and real object, The sun and it's aura, object and mirage.
The dependent origination generates the false 'I' which is nothing but the becoming.
Then can one conclude the cessation of becoming is also carried out... | 2021/10/07 | [
"https://buddhism.stackexchange.com/questions/45964",
"https://buddhism.stackexchange.com",
"https://buddhism.stackexchange.com/users/12115/"
] | "governed by the mind" suggest that there is one who is governed. Once you enter the 2nd refuge of the 3 jewels of Buddhism (taking refuge in the Dharma) and the teacher and the teaching as localized sources melt away, you become one with all , therefore the continued teaching and realizations do not flow from a person... | You cannot, not at least until you are enlightened & choose to do so.
What you can do is cease identification with the thought; detach yourself from the one who is doing the thinking. Karma will still play out for you, things happen, situations occur, thoughts arise. You can't really stop this.
The waves still as a c... |
3,808 | By default, `populateState` seems to limit a call to any model's `get('Items')` function to 20 items.
How can this be overridden - by re-writing `populateState`? By writing a separate function in the model? I've gone for the second option...
```
public function getAll(){
return $this->_getList($this->getListQuery... | 2014/07/30 | [
"https://joomla.stackexchange.com/questions/3808",
"https://joomla.stackexchange.com",
"https://joomla.stackexchange.com/users/90/"
] | To answer the question in the title about "setting" the limit, this is done in the Joomla global configuration: "Default List Limit".
To override, Joomla components generally seem to use this in the model:
Using `$limit = 0` shows all items
```
protected function populateState($ordering = null, $direction = null)
{
... | **Try this also**
```
protected function populateState($ordering = null, $direction = null)
{
// Load the list state.
$this->setState('list.start', 0);
$this->setState('list.limit', 10);
}
``` |
3,808 | By default, `populateState` seems to limit a call to any model's `get('Items')` function to 20 items.
How can this be overridden - by re-writing `populateState`? By writing a separate function in the model? I've gone for the second option...
```
public function getAll(){
return $this->_getList($this->getListQuery... | 2014/07/30 | [
"https://joomla.stackexchange.com/questions/3808",
"https://joomla.stackexchange.com",
"https://joomla.stackexchange.com/users/90/"
] | To answer the question in the title about "setting" the limit, this is done in the Joomla global configuration: "Default List Limit".
To override, Joomla components generally seem to use this in the model:
Using `$limit = 0` shows all items
```
protected function populateState($ordering = null, $direction = null)
{
... | Like others have said - put this in the model's populateState function
```
$this->setState('list.limit', $limit); #limit=0 removes limit
$this->setState('list.start', $start);
```
But you must make sure that these lines are AFTER
```
parent::populateState($order, $dir);
```
or the parent class will override your... |
3,808 | By default, `populateState` seems to limit a call to any model's `get('Items')` function to 20 items.
How can this be overridden - by re-writing `populateState`? By writing a separate function in the model? I've gone for the second option...
```
public function getAll(){
return $this->_getList($this->getListQuery... | 2014/07/30 | [
"https://joomla.stackexchange.com/questions/3808",
"https://joomla.stackexchange.com",
"https://joomla.stackexchange.com/users/90/"
] | Like others have said - put this in the model's populateState function
```
$this->setState('list.limit', $limit); #limit=0 removes limit
$this->setState('list.start', $start);
```
But you must make sure that these lines are AFTER
```
parent::populateState($order, $dir);
```
or the parent class will override your... | **Try this also**
```
protected function populateState($ordering = null, $direction = null)
{
// Load the list state.
$this->setState('list.start', 0);
$this->setState('list.limit', 10);
}
``` |
23,977,264 | I was wondering how I can initialize a `std::vector` of strings, without having to use a bunch of `push_back`'s in *Visual Studio Ultimate 2012*.
---
I've tried `vector<string> test = {"hello", "world"}`, but that gave me the following error:
>
> `Error: initialization with '{...}' is not allowed for an object of t... | 2014/06/01 | [
"https://Stackoverflow.com/questions/23977264",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2535589/"
] | **The problem**
You'll have to upgrade to a more recent compiler version (and standard library implementation), if you'd like to use what you have in your snippet.
*VS2012* [doesn't support](http://msdn.microsoft.com/en-us/library/hh567368.aspx) `std::initializer_list`, which means that the overload among `std::vecto... | **1. Why do I receive the error?**
Visual Studio 2012 doesn't support list initialization before the [2012 November update](https://support.microsoft.com/en-us/help/2797915/description-of-visual-studio-2012-update-1) according to this [question](https://stackoverflow.com/questions/12654394/initializer-list-not-working-... |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | In addition to what Chris stated, it also gave Amidala an more ready excuse to be around the Jedi, Anakin and JarJar in a non-formal environment where discussion might flow more freely. An attendant to the Queen would be expected to be in attendance to the Queen whenever possible and allows little time to just "hang ou... | The decision to ask her to clean the droid seems to have been to give Padmé an opportunity to interact directly with the Queen *without it seeming like she's consulting her*. Presumably if Padmé had disagreed, she could have shaken her head sadly as she looked at how dirty the droid was.
It's a little clearer in the f... |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | The decision to ask her to clean the droid seems to have been to give Padmé an opportunity to interact directly with the Queen *without it seeming like she's consulting her*. Presumably if Padmé had disagreed, she could have shaken her head sadly as she looked at how dirty the droid was.
It's a little clearer in the f... | The smile that Sabe gives Padme after she orders her to do it is quite telling. Like it's some kind of joke. Whether it's a joke that she's making her do something menial, or a joke that "Hey, we're going to pull off you infiiltrating the strangers' ranks" is unknown. |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | In addition to what Chris stated, it also gave Amidala an more ready excuse to be around the Jedi, Anakin and JarJar in a non-formal environment where discussion might flow more freely. An attendant to the Queen would be expected to be in attendance to the Queen whenever possible and allows little time to just "hang ou... | Perhaps Padmé *wanted* to clean the droid--both to learn more about the people she was traveling with, and the droid that had saved her and her ship. She didn't seem to treat it as an onerous task, did she? |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | 1. It underscores the subterfuge - if the "queen" were deferential and reluctant to use a particular handmaiden as a servant, that would raise suspicions. If Padme wanted to be seen as a servant, she would have walk the walk.
2. I think that Sabé was well-trained enough to handle the situation. They were out of danger,... | I always thought it was Sabe playing a joke on her friend the Queen. The Queen and her handmaidens are supposed to be very close (look at how distraught Padme was when Corde, who wasn't even HER handmaiden was killed) so maybe Sabe felt secure enough in their friendship to make her do dirty work. I know that if my best... |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | The decision to ask her to clean the droid seems to have been to give Padmé an opportunity to interact directly with the Queen *without it seeming like she's consulting her*. Presumably if Padmé had disagreed, she could have shaken her head sadly as she looked at how dirty the droid was.
It's a little clearer in the f... | Perhaps Padmé *wanted* to clean the droid--both to learn more about the people she was traveling with, and the droid that had saved her and her ship. She didn't seem to treat it as an onerous task, did she? |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | In addition to what Chris stated, it also gave Amidala an more ready excuse to be around the Jedi, Anakin and JarJar in a non-formal environment where discussion might flow more freely. An attendant to the Queen would be expected to be in attendance to the Queen whenever possible and allows little time to just "hang ou... | I always thought it was Sabe playing a joke on her friend the Queen. The Queen and her handmaidens are supposed to be very close (look at how distraught Padme was when Corde, who wasn't even HER handmaiden was killed) so maybe Sabe felt secure enough in their friendship to make her do dirty work. I know that if my best... |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | I always thought it was Sabe playing a joke on her friend the Queen. The Queen and her handmaidens are supposed to be very close (look at how distraught Padme was when Corde, who wasn't even HER handmaiden was killed) so maybe Sabe felt secure enough in their friendship to make her do dirty work. I know that if my best... | Perhaps Padmé *wanted* to clean the droid--both to learn more about the people she was traveling with, and the droid that had saved her and her ship. She didn't seem to treat it as an onerous task, did she? |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | 1. It underscores the subterfuge - if the "queen" were deferential and reluctant to use a particular handmaiden as a servant, that would raise suspicions. If Padme wanted to be seen as a servant, she would have walk the walk.
2. I think that Sabé was well-trained enough to handle the situation. They were out of danger,... | The smile that Sabe gives Padme after she orders her to do it is quite telling. Like it's some kind of joke. Whether it's a joke that she's making her do something menial, or a joke that "Hey, we're going to pull off you infiiltrating the strangers' ranks" is unknown. |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | 1. It underscores the subterfuge - if the "queen" were deferential and reluctant to use a particular handmaiden as a servant, that would raise suspicions. If Padme wanted to be seen as a servant, she would have walk the walk.
2. I think that Sabé was well-trained enough to handle the situation. They were out of danger,... | The decision to ask her to clean the droid seems to have been to give Padmé an opportunity to interact directly with the Queen *without it seeming like she's consulting her*. Presumably if Padmé had disagreed, she could have shaken her head sadly as she looked at how dirty the droid was.
It's a little clearer in the f... |
10,598 | Reading [the answer to a question about Sabé](https://scifi.stackexchange.com/a/10590/2565) (the Amidala stand-in) I remembered that I always wondered why she ordered the actual queen to scrub R2-D2. There were enough actual servants who could have done it, so why Padmé? If that wasn't enough, after giving the actual q... | 2012/02/07 | [
"https://scifi.stackexchange.com/questions/10598",
"https://scifi.stackexchange.com",
"https://scifi.stackexchange.com/users/2565/"
] | I always thought it was Sabe playing a joke on her friend the Queen. The Queen and her handmaidens are supposed to be very close (look at how distraught Padme was when Corde, who wasn't even HER handmaiden was killed) so maybe Sabe felt secure enough in their friendship to make her do dirty work. I know that if my best... | The smile that Sabe gives Padme after she orders her to do it is quite telling. Like it's some kind of joke. Whether it's a joke that she's making her do something menial, or a joke that "Hey, we're going to pull off you infiiltrating the strangers' ranks" is unknown. |
60,989,333 | I have array:
`const someArray = ['one', 'two', 'three'];`
and I have type:
`type SomeType = 'one' | 'two' | 'three';`
How can I get `SomeType` from `someArray`? | 2020/04/02 | [
"https://Stackoverflow.com/questions/60989333",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10561224/"
] | You can not, because TypeScript is not a dependently-typed language.
TypeScript, like almost any other well known statically typed language in existence at the moment, can create types for values, but not create types from values.
So you can create a type for your values:
`const someArray: SomeType[] = ['one', 'two'... | by 'filter' to ergodic return satisfy condition‘s element |
60,989,333 | I have array:
`const someArray = ['one', 'two', 'three'];`
and I have type:
`type SomeType = 'one' | 'two' | 'three';`
How can I get `SomeType` from `someArray`? | 2020/04/02 | [
"https://Stackoverflow.com/questions/60989333",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10561224/"
] | You can, at the cost that you have to apply `as const` assertion to `someArray`.
```
const someArray = ['one', 'two', 'three'] as const;
/* ^------- IMPORTANT!
otherwise it'll just be `string[]` */
type GetItem<T> = T extends ReadonlyArr... | by 'filter' to ergodic return satisfy condition‘s element |
60,989,333 | I have array:
`const someArray = ['one', 'two', 'three'];`
and I have type:
`type SomeType = 'one' | 'two' | 'three';`
How can I get `SomeType` from `someArray`? | 2020/04/02 | [
"https://Stackoverflow.com/questions/60989333",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10561224/"
] | I found an even simpler solution.
```
const someArray = ['one', 'two', 'three'] as const;
/* ^------- IMPORTANT!
otherwise it'll just be `string[]` */
type SomeType = typeof someArray[number]; // 'one' | 'two' | 'three'
``` | by 'filter' to ergodic return satisfy condition‘s element |
60,989,333 | I have array:
`const someArray = ['one', 'two', 'three'];`
and I have type:
`type SomeType = 'one' | 'two' | 'three';`
How can I get `SomeType` from `someArray`? | 2020/04/02 | [
"https://Stackoverflow.com/questions/60989333",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10561224/"
] | You can, at the cost that you have to apply `as const` assertion to `someArray`.
```
const someArray = ['one', 'two', 'three'] as const;
/* ^------- IMPORTANT!
otherwise it'll just be `string[]` */
type GetItem<T> = T extends ReadonlyArr... | You can not, because TypeScript is not a dependently-typed language.
TypeScript, like almost any other well known statically typed language in existence at the moment, can create types for values, but not create types from values.
So you can create a type for your values:
`const someArray: SomeType[] = ['one', 'two'... |
60,989,333 | I have array:
`const someArray = ['one', 'two', 'three'];`
and I have type:
`type SomeType = 'one' | 'two' | 'three';`
How can I get `SomeType` from `someArray`? | 2020/04/02 | [
"https://Stackoverflow.com/questions/60989333",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10561224/"
] | You can, at the cost that you have to apply `as const` assertion to `someArray`.
```
const someArray = ['one', 'two', 'three'] as const;
/* ^------- IMPORTANT!
otherwise it'll just be `string[]` */
type GetItem<T> = T extends ReadonlyArr... | I found an even simpler solution.
```
const someArray = ['one', 'two', 'three'] as const;
/* ^------- IMPORTANT!
otherwise it'll just be `string[]` */
type SomeType = typeof someArray[number]; // 'one' | 'two' | 'three'
``` |
43,798 | I have been playing piano for almost 7 years. I am trying to learn "Flight of the Bumblebee", Rachmaninoff version. The problem is that the left hand has certain chords that my fingers cannot reach. There is AEC#, C#AE, F#ADA, and maybe more. I am able to reach an octave and one note over an octave, but thats it. I hav... | 2016/04/23 | [
"https://music.stackexchange.com/questions/43798",
"https://music.stackexchange.com",
"https://music.stackexchange.com/users/28137/"
] | Very large chords like the one you mention are quite common in fact in classical romantic music piano literature.
Basics about this issue is, play like an arpeggio (alephzero answer). Most pianists do that indeed. This is absolutely normal, as even pianists with very long fingers can't reach some insane chords (see i... | Just play the chords that you can't reach as arpeggios (rolled chords). When you get the piece up to the correct tempo, nobody will notice. For consistency, you might want to roll some of the chords that you *can* reach, as well as the ones you can't.
(The score is here: <http://imslp.org/wiki/Special:ImagefromIndex/9... |
43,798 | I have been playing piano for almost 7 years. I am trying to learn "Flight of the Bumblebee", Rachmaninoff version. The problem is that the left hand has certain chords that my fingers cannot reach. There is AEC#, C#AE, F#ADA, and maybe more. I am able to reach an octave and one note over an octave, but thats it. I hav... | 2016/04/23 | [
"https://music.stackexchange.com/questions/43798",
"https://music.stackexchange.com",
"https://music.stackexchange.com/users/28137/"
] | Very large chords like the one you mention are quite common in fact in classical romantic music piano literature.
Basics about this issue is, play like an arpeggio (alephzero answer). Most pianists do that indeed. This is absolutely normal, as even pianists with very long fingers can't reach some insane chords (see i... | In the specific case of Rachmaninoff's arrangement of "Flight of the Bumblebee" there is an option that works well for pianists who find arpeggiation difficult or unworkable.
### The ACE chord (e.g., mm. 9-13)
* Play the low A and E with the left hand.
* Play the middle C with the right hand.
[. |
31,284,260 | I am using Intellij idea IDE. Whenever I try to copy and paste any code from my browser to the IDE, it is not being pasted. Actually the last selection in the IDE is pasted every time. However if I paste it in any other application like notepad, it works fine.
What do I need to do? | 2015/07/08 | [
"https://Stackoverflow.com/questions/31284260",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3186914/"
] | I found the same problem with IntelliJ 14.1.4 on Windows 7. I copy something external, use `Ctrl+V` in the IDE, but the last clipboard from the IDE is pasted instead.
I was able to resolve this by clearing the IDE clipboard, you can do this with `Ctrl+Shift+V` which opens the **Paste from History** dialog, here you wi... | Happens to me quite often on win 7. Seems to be after idea is running for longer period of time / through suspend. Standard close and relaunch of all idea windows works. Is the same in versions 14 and 15 (no tested other). |
66,507,096 | I wanted to create something simple like void Function(struct str) to calculate paralel in barriers sync, but seems to not be so simple, so I followed this:
<https://learn.microsoft.com/en-us/windows/win32/procthread/creating-threads>
and some other topics, but without success. Couldnt find a solution. Code is all in o... | 2021/03/06 | [
"https://Stackoverflow.com/questions/66507096",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10705548/"
] | Note how when you cast `lpParam` to a `dectectorData*` you should cast like this: `(detectorData*)lpParam` not `(detectorData)lpParam`. (Note the `*` denoting a pointer.) | Since I am using C++, there is already std::thread class.
So my simple task can be done by this code:
```
void detAndComputeT(detectorData &data) {
Ptr<SIFT> detector = cv::SIFT::create();
detector->detectAndCompute(data.image, Mat(), data.keypoints, data.descriptors);
}
```
and
```
std::thread threads2[2];
detecto... |
12,573,839 | I am a newby to design and looking now into the use of background instead of foreground images, which is a common practice.
I look at the techniques used, and see that:
* you usually need to explicitly state the dimensions of the image (and set the foreground element to these dimensions)
* you need to make the foreg... | 2012/09/24 | [
"https://Stackoverflow.com/questions/12573839",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/440925/"
] | The main difference is that in the `img` tag the image is *hardcoded*.
With CSS you can create different designs, switch between them, redesign the page, without altering the source code. To see the power of CSS, check <http://www.csszengarden.com/>, all the pages use the same HTML source, but with different CSS layou... | One of the main points of *image replacement* is to use your site title in a `h1` tag for good SEO, and then hiding the text and replacing it with a custom logo.
This also makes your site more accessible. Say for example, your user has CSS disabled for whatever reason (screenreaders, maybe). They would still see the t... |
12,573,839 | I am a newby to design and looking now into the use of background instead of foreground images, which is a common practice.
I look at the techniques used, and see that:
* you usually need to explicitly state the dimensions of the image (and set the foreground element to these dimensions)
* you need to make the foreg... | 2012/09/24 | [
"https://Stackoverflow.com/questions/12573839",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/440925/"
] | The main difference is that in the `img` tag the image is *hardcoded*.
With CSS you can create different designs, switch between them, redesign the page, without altering the source code. To see the power of CSS, check <http://www.csszengarden.com/>, all the pages use the same HTML source, but with different CSS layou... | The goal is to separate content from presentation. HTML should contain just content, and all presentation should be moved to the CSS. Once you achieve that, you gain a few useful side effects:
* The CSS (presentational code) is cached by the user's browser, and each HTML file requested is smaller. This also has some S... |
12,573,839 | I am a newby to design and looking now into the use of background instead of foreground images, which is a common practice.
I look at the techniques used, and see that:
* you usually need to explicitly state the dimensions of the image (and set the foreground element to these dimensions)
* you need to make the foreg... | 2012/09/24 | [
"https://Stackoverflow.com/questions/12573839",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/440925/"
] | The main difference is that in the `img` tag the image is *hardcoded*.
With CSS you can create different designs, switch between them, redesign the page, without altering the source code. To see the power of CSS, check <http://www.csszengarden.com/>, all the pages use the same HTML source, but with different CSS layou... | One thing to consider as a benefit to using CSS for images is that you can load all your design images (images for UI elements, etc) with one http request rather than an http request for each individual image using a sprite. One large image that contains a grid of all your images.
As its been stated before, content im... |
12,573,839 | I am a newby to design and looking now into the use of background instead of foreground images, which is a common practice.
I look at the techniques used, and see that:
* you usually need to explicitly state the dimensions of the image (and set the foreground element to these dimensions)
* you need to make the foreg... | 2012/09/24 | [
"https://Stackoverflow.com/questions/12573839",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/440925/"
] | The goal is to separate content from presentation. HTML should contain just content, and all presentation should be moved to the CSS. Once you achieve that, you gain a few useful side effects:
* The CSS (presentational code) is cached by the user's browser, and each HTML file requested is smaller. This also has some S... | One of the main points of *image replacement* is to use your site title in a `h1` tag for good SEO, and then hiding the text and replacing it with a custom logo.
This also makes your site more accessible. Say for example, your user has CSS disabled for whatever reason (screenreaders, maybe). They would still see the t... |
12,573,839 | I am a newby to design and looking now into the use of background instead of foreground images, which is a common practice.
I look at the techniques used, and see that:
* you usually need to explicitly state the dimensions of the image (and set the foreground element to these dimensions)
* you need to make the foreg... | 2012/09/24 | [
"https://Stackoverflow.com/questions/12573839",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/440925/"
] | One thing to consider as a benefit to using CSS for images is that you can load all your design images (images for UI elements, etc) with one http request rather than an http request for each individual image using a sprite. One large image that contains a grid of all your images.
As its been stated before, content im... | One of the main points of *image replacement* is to use your site title in a `h1` tag for good SEO, and then hiding the text and replacing it with a custom logo.
This also makes your site more accessible. Say for example, your user has CSS disabled for whatever reason (screenreaders, maybe). They would still see the t... |
2,967,436 | How can i form of the matrix representation in the following exercise?
>
> Given the linear maps $f$ and $g$
>
>
> $$f\left(\begin{bmatrix}\lambda\_1\\ \lambda\_2\\ \lambda\_3\end{bmatrix}\right)=\begin{bmatrix}\lambda\_3-\lambda\_1\\\lambda\_2-\lambda\_1\end{bmatrix}\\ g\left(\begin{bmatrix}\mu\_1\\\mu\_2\end{bmat... | 2018/10/23 | [
"https://math.stackexchange.com/questions/2967436",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/605276/"
] | The matrix representation of $T:\Bbb R^n\to\Bbb R^m$ (in the canonical basis) is simply the matrix $$\begin{pmatrix}T(e\_1)& T(e\_2)&\cdots &T(e\_n)\end{pmatrix}.$$
This can be easily computed in this instance. | $f$ is represented (in the standard bases) by $$M\_f= \begin{bmatrix} -1 & 0 & 1\\ -1 & 1 & 0\end{bmatrix}$$
and $g$ by
$$M\_g= \begin{bmatrix}
-1 & 1\\
-2 & 0\\
1 & 1
\end{bmatrix}$$
Now compute $M\_g M\_f$ as matrices |
19,037 | **Thought 1**
```
public interface IRepository<T> : IDisposable where T : class
{
IQueryable<T> Fetch();
IEnumerable<T> GetAll();
IEnumerable<T> Find(Func<T, bool> predicate);
T Single(Func<T, bool> predicate);
T First... | 2012/11/26 | [
"https://codereview.stackexchange.com/questions/19037",
"https://codereview.stackexchange.com",
"https://codereview.stackexchange.com/users/7511/"
] | You should use `Expression<Func<T, bool>>` as predicates on your interface and have the `RepositoryBase` implement that interface.
By only using `Func`, you won't get translation to L2E etc, but will have to enumerate the entire DB table before you can evaluate the `Func`.
The interface can be mocked, hence unit-tested... | Reinventing the wheel
---------------------
If you need a generic repository class use IObjectSet for base type and implement it if needed (in production code it is not needed, in tests you can use an IList<> as backend).
Leek on the abstraction
-----------------------
Repositories aren't supposed to have Save metho... |
3,529,430 | I try to generate a trigger, in the trigger statement I have to set a column of type decimal(17,3) with the actual timestamp or the seconds of unix timestamp, but could not find a solution. | 2010/08/20 | [
"https://Stackoverflow.com/questions/3529430",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/275837/"
] | One definition of foldr is:
```
foldr :: (a -> b -> b) -> b -> [a] -> b
foldr f acc [] = acc
foldr f acc (x:xs) = f x (foldr f acc xs)
```
The [wikibook on Haskell](http://en.wikibooks.org/wiki/Haskell/List_processing) has a nice graph on foldr (and on other folds, too):
```
: ... | You can actually easily visualize it for yourself:
```
import Text.Printf
showOp f = f (printf "(%s op %s)") "0" ["1","2","3"]
```
then
```
Main> showOp foldr
"(1 op (2 op (3 op 0)))"
Main> showOp foldl
"(((0 op 1) op 2) op 3)"
Main> showOp scanl
["0","(0 op 1)","((0 op 1) op 2)","(((0 op 1) op 2) op 3)"]
``` |
3,529,430 | I try to generate a trigger, in the trigger statement I have to set a column of type decimal(17,3) with the actual timestamp or the seconds of unix timestamp, but could not find a solution. | 2010/08/20 | [
"https://Stackoverflow.com/questions/3529430",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/275837/"
] | One definition of foldr is:
```
foldr :: (a -> b -> b) -> b -> [a] -> b
foldr f acc [] = acc
foldr f acc (x:xs) = f x (foldr f acc xs)
```
The [wikibook on Haskell](http://en.wikibooks.org/wiki/Haskell/List_processing) has a nice graph on foldr (and on other folds, too):
```
: ... | [This was supposed to be a comment on delnan's remark, but was too wordy...]
Yoon, you can open a private 'conversation' with `lambdabot` on the #haskell irc (e.g. at <http://webchat.freenode.net/> ). She has a simple reflection ability, so you can type meaningless letters, e.g.
```
Yoon: > foldr (\x y -> 2*x + y... |
3,529,430 | I try to generate a trigger, in the trigger statement I have to set a column of type decimal(17,3) with the actual timestamp or the seconds of unix timestamp, but could not find a solution. | 2010/08/20 | [
"https://Stackoverflow.com/questions/3529430",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/275837/"
] | You can actually easily visualize it for yourself:
```
import Text.Printf
showOp f = f (printf "(%s op %s)") "0" ["1","2","3"]
```
then
```
Main> showOp foldr
"(1 op (2 op (3 op 0)))"
Main> showOp foldl
"(((0 op 1) op 2) op 3)"
Main> showOp scanl
["0","(0 op 1)","((0 op 1) op 2)","(((0 op 1) op 2) op 3)"]
``` | [This was supposed to be a comment on delnan's remark, but was too wordy...]
Yoon, you can open a private 'conversation' with `lambdabot` on the #haskell irc (e.g. at <http://webchat.freenode.net/> ). She has a simple reflection ability, so you can type meaningless letters, e.g.
```
Yoon: > foldr (\x y -> 2*x + y... |
53,495,531 | We are extracting a large amount of JSON objects from an EVE Online API, and deseralizing them into EveObjModel objects using Newtonsoft.Json.JsonConvert. From there we want to create a list of unique objects, i.e. the most expensive of each type\_id. I have pasted the dataContract below as well.
**The problem:** Thi... | 2018/11/27 | [
"https://Stackoverflow.com/questions/53495531",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7766834/"
] | It's not surprising that the process is slow, because the algorithm you are using (with nested loop) has at least quadratic O(N\*N) time complexity, which with such size of data sets is really slow.
One way is to use LINQ `GroupBy` operator, which internally uses hash based lookup, hence has theoretically O(N) time co... | You should be able to use `Enumerable.GroupBy()` to do this fairly efficiently:
```
var grouped = buyList.GroupBy(item => item.type_id);
var uniqueBuyList = new List<EveObjModel>();
foreach (var group in grouped)
{
var combined = group.First();
combined.price = group.Max(item => item.price);
uniqueBuyLis... |
53,495,531 | We are extracting a large amount of JSON objects from an EVE Online API, and deseralizing them into EveObjModel objects using Newtonsoft.Json.JsonConvert. From there we want to create a list of unique objects, i.e. the most expensive of each type\_id. I have pasted the dataContract below as well.
**The problem:** Thi... | 2018/11/27 | [
"https://Stackoverflow.com/questions/53495531",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7766834/"
] | You should be able to use `Enumerable.GroupBy()` to do this fairly efficiently:
```
var grouped = buyList.GroupBy(item => item.type_id);
var uniqueBuyList = new List<EveObjModel>();
foreach (var group in grouped)
{
var combined = group.First();
combined.price = group.Max(item => item.price);
uniqueBuyLis... | We can sort given List by ascending `type_id` and then by ascending `price` and reverse it. So that, `EveObjModel` object with `higher price` come first for every unique `type_id`.
Then, we may go through object List again and pick up the unique type\_id that come fist and skip same type\_id then after.
As we a... |
53,495,531 | We are extracting a large amount of JSON objects from an EVE Online API, and deseralizing them into EveObjModel objects using Newtonsoft.Json.JsonConvert. From there we want to create a list of unique objects, i.e. the most expensive of each type\_id. I have pasted the dataContract below as well.
**The problem:** Thi... | 2018/11/27 | [
"https://Stackoverflow.com/questions/53495531",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7766834/"
] | It's not surprising that the process is slow, because the algorithm you are using (with nested loop) has at least quadratic O(N\*N) time complexity, which with such size of data sets is really slow.
One way is to use LINQ `GroupBy` operator, which internally uses hash based lookup, hence has theoretically O(N) time co... | We can sort given List by ascending `type_id` and then by ascending `price` and reverse it. So that, `EveObjModel` object with `higher price` come first for every unique `type_id`.
Then, we may go through object List again and pick up the unique type\_id that come fist and skip same type\_id then after.
As we a... |
19,131,927 | ```
void replace3sWith4s(int[] replace){
for (int i = 0;i<replace.length;i++){
if (replace[i]==3);{
replace[i]=4;
}
}
}
```
My program is replacing all numbers with #4 but I want to have an array that contains 3,
takes an integer array, and changes any element that has the value 3 to instead... | 2013/10/02 | [
"https://Stackoverflow.com/questions/19131927",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2837656/"
] | ```
if (replace[i]==3);
^^^
```
Remove the semicolon.
It should be
```
if (replace[i]==3) {
replace[i]=4;
}
```
The semicolon changes the meaning to
```
if (replace[i]==3)
;//do nothing
// Separate New block
{
replace[i]=4;
}
``` | also You can try this method at if statement according to your array type
```
if (replace[i].equals("3")){
replace[i]=4;
```
} |
19,131,927 | ```
void replace3sWith4s(int[] replace){
for (int i = 0;i<replace.length;i++){
if (replace[i]==3);{
replace[i]=4;
}
}
}
```
My program is replacing all numbers with #4 but I want to have an array that contains 3,
takes an integer array, and changes any element that has the value 3 to instead... | 2013/10/02 | [
"https://Stackoverflow.com/questions/19131927",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2837656/"
] | ```
(replace[i]==3);
```
Is like writing
```
(replace[i]==3) { }
```
Which does nothing.
Your code is equivalent to this code:
```
void replace3sWith4s(int[] replace){
for (int i = 0;i<replace.length;i++){
if (replace[i]==3) { }
replace[i]=4; //Always reachable
}
}
}
```
To fix your co... | also You can try this method at if statement according to your array type
```
if (replace[i].equals("3")){
replace[i]=4;
```
} |
22,343 | I saw this question somewhere in the Internet(I forgot the source) and I think this forum is a good place to ask it.
According to what I know, the atoms in a persons body are replaced every certain amount of years:
<https://skeptics.stackexchange.com/questions/18427/are-all-the-atoms-in-our-bodies-replaced-on-a-regula... | 2015/03/15 | [
"https://philosophy.stackexchange.com/questions/22343",
"https://philosophy.stackexchange.com",
"https://philosophy.stackexchange.com/users/13954/"
] | Atoms do not contain little tags that say "I am part of user63152", and whose unique properties determine the actions of user63152. Indeed, aside from differences in isotopes, and a handful of observables like nuclear spin, atoms of the same type are indistinguishable from each other.
Thus, we needn't care whether the... | What is the purpose of punishment? If it is to link consequences to decisions, then the question is whether that old collection of molecules should have predicted the damage it would cause any better than this new collection of molecules.
Our notions of learning imply that behavior is a feedback loop and the consisten... |
22,343 | I saw this question somewhere in the Internet(I forgot the source) and I think this forum is a good place to ask it.
According to what I know, the atoms in a persons body are replaced every certain amount of years:
<https://skeptics.stackexchange.com/questions/18427/are-all-the-atoms-in-our-bodies-replaced-on-a-regula... | 2015/03/15 | [
"https://philosophy.stackexchange.com/questions/22343",
"https://philosophy.stackexchange.com",
"https://philosophy.stackexchange.com/users/13954/"
] | Atoms do not contain little tags that say "I am part of user63152", and whose unique properties determine the actions of user63152. Indeed, aside from differences in isotopes, and a handful of observables like nuclear spin, atoms of the same type are indistinguishable from each other.
Thus, we needn't care whether the... | It seems to me that this is just a reformulation of Theseus' paradox. Plutarch notes in his biography of Theseus that the ship that Theseus and the other Athenian youths returned upon was preserved by the city of Athens through the ages. As various planks and rails rotted, they were replaced leading to the question com... |
22,343 | I saw this question somewhere in the Internet(I forgot the source) and I think this forum is a good place to ask it.
According to what I know, the atoms in a persons body are replaced every certain amount of years:
<https://skeptics.stackexchange.com/questions/18427/are-all-the-atoms-in-our-bodies-replaced-on-a-regula... | 2015/03/15 | [
"https://philosophy.stackexchange.com/questions/22343",
"https://philosophy.stackexchange.com",
"https://philosophy.stackexchange.com/users/13954/"
] | Arne Naess wrote many essays about the Self. In them, he argued for a concept called the Ecological Self, but along the way he used a series of phrases to challenge commonly held approaches to defining the self. Such class of phrase pairs looked like:
* I enjoy listening to Mozart.
* My body enjoys listening to Mozart... | What is the purpose of punishment? If it is to link consequences to decisions, then the question is whether that old collection of molecules should have predicted the damage it would cause any better than this new collection of molecules.
Our notions of learning imply that behavior is a feedback loop and the consisten... |
22,343 | I saw this question somewhere in the Internet(I forgot the source) and I think this forum is a good place to ask it.
According to what I know, the atoms in a persons body are replaced every certain amount of years:
<https://skeptics.stackexchange.com/questions/18427/are-all-the-atoms-in-our-bodies-replaced-on-a-regula... | 2015/03/15 | [
"https://philosophy.stackexchange.com/questions/22343",
"https://philosophy.stackexchange.com",
"https://philosophy.stackexchange.com/users/13954/"
] | Arne Naess wrote many essays about the Self. In them, he argued for a concept called the Ecological Self, but along the way he used a series of phrases to challenge commonly held approaches to defining the self. Such class of phrase pairs looked like:
* I enjoy listening to Mozart.
* My body enjoys listening to Mozart... | It seems to me that this is just a reformulation of Theseus' paradox. Plutarch notes in his biography of Theseus that the ship that Theseus and the other Athenian youths returned upon was preserved by the city of Athens through the ages. As various planks and rails rotted, they were replaced leading to the question com... |
58,557,803 | I'm want to add **OR** condition in the JSON query of Cube.js. But once I added one more condition in the filter it always adds **AND** condition in SQL query.
Below is the JSON query that I'm trying.
```
{
"dimensions": [
"Employee.name",
"Employee.company"
],
"timeDimensions": [],
"measures": [],
... | 2019/10/25 | [
"https://Stackoverflow.com/questions/58557803",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12118067/"
] | API support for logical operators isn't shipped yet. Meanwhile there're several workarounds:
1. Define dimension that mimics **OR** behavior. In your case it's
```js
cube(`Employee`, {
// ...
dimensions: {
companyAndName: {
sql: `CONCAT(${company}, ' ', ${name})`,
type: `string`
}
}
});
```
2. D... | this is how you do it
```
{
or: [
{
"dimension": "Employee.company",
"operator": "contains",
"values": [
"soft"
]
},
{
"dimension": "Employee.name",
"operator": "contains",
"values": [
... |
43,374,103 | Being rather new to socket programming and threading in general, my issue might be stemming from a misunderstanding of how they work. I am trying to create something that acts as both a client and a server using threading.
Following:
<https://docs.python.org/3/library/socketserver.html#asynchronous-mixins>
I created ... | 2017/04/12 | [
"https://Stackoverflow.com/questions/43374103",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2763113/"
] | You could do something like below. Your elements need a `float:left;`.
Though there are far better ways to handle this. You should really change your HTML to use `span` instead of `div` to achieve the final solution.
```css
/* CSS used here will be applied after bootstrap.css */emergency{
color: #1D1060;
}
.... | Your `<p>` and `#currState` are block level elements, meaning they will take up the full-width of screen and so naturally "Normal" will be on next line.
A hack fix would be to set both elements to `display: inline-block;` but I think your code could use a restructuring. You are using inline styles and `<br>` when not ... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Here's a better suggestion: edits should only cause questions to go into the reopen queue if the OP is the editor.
Let's consider every possible close reason, and then decide who is more likely to make an edit that makes the question reopen-worthy:
* Duplicate: If the question is not a duplicate, the OP is the one wh... | >
> My procedure so far has been to go back to the stupidly-edited question and mod flag them with a comment that the edit is bad and whoever approved it should be review-banned, but seriously... that isn't instant, I have better things to do with my day, and I'm not the one who approved the bad edit and caused the pr... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Here's a better suggestion: edits should only cause questions to go into the reopen queue if the OP is the editor.
Let's consider every possible close reason, and then decide who is more likely to make an edit that makes the question reopen-worthy:
* Duplicate: If the question is not a duplicate, the OP is the one wh... | You know what? I'm not seeing it.
Out the 10 I've reviewed, not all where pushed to the queue with edits. The 6 which were, are done by users which fall in one of these two categories:
* Are the OP
* Have >2k reputation
My guess is that my filters rock (only reviewing off topic or primarily opinion based). |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Assuming that such edits were made by a person without edit privileges, each such harmful edit would have ended up in the suggested edit review queue. If so, the root of the problem lies there.
When doing suggested-edit reviews of questions, the reviewer needs to consider if the question makes sense in the first place... | You know what? I'm not seeing it.
Out the 10 I've reviewed, not all where pushed to the queue with edits. The 6 which were, are done by users which fall in one of these two categories:
* Are the OP
* Have >2k reputation
My guess is that my filters rock (only reviewing off topic or primarily opinion based). |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Maybe when a question is edited the person doing the edit should be asked if they wish to “vote to reopen”. Often even as the OP I may edit a question (for example a duplicate) to make it clearer, but not wish it to be reopened that that point.
So prompt for “should be considered to be reopened” on an edit, but don’t ... | You know what? I'm not seeing it.
Out the 10 I've reviewed, not all where pushed to the queue with edits. The 6 which were, are done by users which fall in one of these two categories:
* Are the OP
* Have >2k reputation
My guess is that my filters rock (only reviewing off topic or primarily opinion based). |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | >
> *meta note: I originally provided data for only 14 days here; I've since found myself referencing this post with some frequency, so I've updated it to reflect a full year of data; some of the original commentary may seem odd in light of this.*
>
>
>
Here's how reopen review outcomes break down by [creation tri... | Maybe when a question is edited the person doing the edit should be asked if they wish to “vote to reopen”. Often even as the OP I may edit a question (for example a duplicate) to make it clearer, but not wish it to be reopened that that point.
So prompt for “should be considered to be reopened” on an edit, but don’t ... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | I think suggestion #2 has some merit as it somewhat attempts to educate users. Along those lines, I am pretty sure most <2k users do not understand that the +2 rep they get for editing the closed post will go away when the post is deleted.
So how about something like this?
* If a question is closed, and <2k user who... | How about a ban on users that edit questions that get review rejected for:
These should be strikes for sure and count very heavily,
* No improvement
* Conflicts with authors intent
things like
* attempt to answer
* me too
* other (comments as answers)
should count towards a ban but with less weight than the other... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | >
> *meta note: I originally provided data for only 14 days here; I've since found myself referencing this post with some frequency, so I've updated it to reflect a full year of data; some of the original commentary may seem odd in light of this.*
>
>
>
Here's how reopen review outcomes break down by [creation tri... | You know what? I'm not seeing it.
Out the 10 I've reviewed, not all where pushed to the queue with edits. The 6 which were, are done by users which fall in one of these two categories:
* Are the OP
* Have >2k reputation
My guess is that my filters rock (only reviewing off topic or primarily opinion based). |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | >
> *meta note: I originally provided data for only 14 days here; I've since found myself referencing this post with some frequency, so I've updated it to reflect a full year of data; some of the original commentary may seem odd in light of this.*
>
>
>
Here's how reopen review outcomes break down by [creation tri... | I think suggestion #2 has some merit as it somewhat attempts to educate users. Along those lines, I am pretty sure most <2k users do not understand that the +2 rep they get for editing the closed post will go away when the post is deleted.
So how about something like this?
* If a question is closed, and <2k user who... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Maybe when a question is edited the person doing the edit should be asked if they wish to “vote to reopen”. Often even as the OP I may edit a question (for example a duplicate) to make it clearer, but not wish it to be reopened that that point.
So prompt for “should be considered to be reopened” on an edit, but don’t ... | How about a ban on users that edit questions that get review rejected for:
These should be strikes for sure and count very heavily,
* No improvement
* Conflicts with authors intent
things like
* attempt to answer
* me too
* other (comments as answers)
should count towards a ban but with less weight than the other... |
355,341 | Recently the Reopen Votes queue has been overrun with questions that have been closed, then edited by a user who is not the asker after the closure, and their edit has been approved.
95% of the time this happens, this approved edit does nothing to attempt to fix the question's content, but consists merely of formattin... | 2017/08/19 | [
"https://meta.stackoverflow.com/questions/355341",
"https://meta.stackoverflow.com",
"https://meta.stackoverflow.com/users/70345/"
] | Assuming that such edits were made by a person without edit privileges, each such harmful edit would have ended up in the suggested edit review queue. If so, the root of the problem lies there.
When doing suggested-edit reviews of questions, the reviewer needs to consider if the question makes sense in the first place... | How about a ban on users that edit questions that get review rejected for:
These should be strikes for sure and count very heavily,
* No improvement
* Conflicts with authors intent
things like
* attempt to answer
* me too
* other (comments as answers)
should count towards a ban but with less weight than the other... |
802,877 | i get following errors when trying to open programs over ssh.
```
$ thunar
Thunar: Cannot open display:
$ libreoffice
Failed to open display
$ firefox
Error: GDK_BACKEND does not match available displays
$ keepassx
keepassx: cannot connect to X server
$ keepass2
Unhandled Exception:
System.TypeInitializationExc... | 2016/07/25 | [
"https://askubuntu.com/questions/802877",
"https://askubuntu.com",
"https://askubuntu.com/users/572440/"
] | It is necessary for you to tell us 3 things.
1. What command did you use to launch your ssh session.
Did you run
```
$ ssh -Y whatever.com
```
or
```
$ ssh -X whatever.com
```
If you had neither -X nor -Y, X11 forwarding won't work
2. Have you edited the ssh client configuration file on the client machine? If ... | Have you disabled ipv6? If so I found the solution!
Add AddressFamily inet to sshd\_config.
Edit:
Perform the following steps:
1. On the server, edit the file /etc/ssh/sshd\_config .
2. The default file should have "AddressFamily inet" commented out. Uncomment it and change the value from its default of "any" to "in... |
20,211,678 | i have this (a rough e.g):
```
<StackPanel>
<StackPanel Orientation="Horizontal">
<Label .../>
<TextBox .../>
<Button Content="Add new input row" ... />
</StackPanel>
</StackPanel>
```
pretty self explanatory, i want to add a new Horizontal StackPanel with every click on the button..
... | 2013/11/26 | [
"https://Stackoverflow.com/questions/20211678",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1900641/"
] | You could use `strsplit` to split your string and then access the array element that you are interested in.
```
mystring = '245 0.00000000 2456171.50000000 1030492816.000 5.14501001 1 IG 5 -1.188022 .... 5.032154 90';
split = strsplit(mystring);
```
If your version of MATLAB is too ... | Here is a piece of code that replicates `%*f` using `repmat` (with cells). It then changes the `%*f` into `%f` at the provided indexes, and finally transform the cells into a `char` vector.
```
f_star_nb = 20;
f_ind = [2 6 9];
f = repmat({'%*f'}, f_star_nb, 1)
f(f_ind) = {'%f'};
f = [f{:}]
``` |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | `fdisk -l` | Depends on how the drive is attached.
ATA/SATA drives should normally be detected on bootup. Look into the boot log (`/var/log/syslog, /var/log/messages`, output of `dmesg`).
There should also be a list of recognized partitions for all partitioned drives under `/proc/partitions`.
For hotplugged drives (e.g. USB) it ... |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | `fdisk -l` | fdisk -l
dmesg
/var/log/message.. |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | `fdisk -l` | The sg\_\* utilities might also be useful:
```
$ sudo sg_map -i
/dev/sg0 /dev/sda ATA WDC WD5000BEVT-2 01.0
/dev/sg1 /dev/scd0 Optiarc BD ROM BC-5500S 1.83
/dev/sg2 /dev/sdb ATA WDC WD5000BEVT-0 01.0
/dev/sg3 /dev/sdc WD PP III Studio II 0817
```
There are lots of other commands in ... |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | `fdisk -l` | For those coming here from a search - this is (currently) an old question with old answers, but there are other newer posts that answer this question better.
The solution I prefer is:
`root# lsblk -io NAME,TYPE,SIZE,MOUNTPOINT,FSTYPE,MODEL`
```
NAME TYPE SIZE MOUNTPOINT FSTYPE MODEL
sdb disk ... |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | For those coming here from a search - this is (currently) an old question with old answers, but there are other newer posts that answer this question better.
The solution I prefer is:
`root# lsblk -io NAME,TYPE,SIZE,MOUNTPOINT,FSTYPE,MODEL`
```
NAME TYPE SIZE MOUNTPOINT FSTYPE MODEL
sdb disk ... | Depends on how the drive is attached.
ATA/SATA drives should normally be detected on bootup. Look into the boot log (`/var/log/syslog, /var/log/messages`, output of `dmesg`).
There should also be a list of recognized partitions for all partitioned drives under `/proc/partitions`.
For hotplugged drives (e.g. USB) it ... |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | For those coming here from a search - this is (currently) an old question with old answers, but there are other newer posts that answer this question better.
The solution I prefer is:
`root# lsblk -io NAME,TYPE,SIZE,MOUNTPOINT,FSTYPE,MODEL`
```
NAME TYPE SIZE MOUNTPOINT FSTYPE MODEL
sdb disk ... | fdisk -l
dmesg
/var/log/message.. |
94,886 | So I have a server that has a few harddrives in it, all formatted and mounted. However I'm told there is another drive attached to it. How do I find out what drives are attached? How do I find out the device filename for this new drive (that's not mounted) | 2009/12/16 | [
"https://serverfault.com/questions/94886",
"https://serverfault.com",
"https://serverfault.com/users/8950/"
] | For those coming here from a search - this is (currently) an old question with old answers, but there are other newer posts that answer this question better.
The solution I prefer is:
`root# lsblk -io NAME,TYPE,SIZE,MOUNTPOINT,FSTYPE,MODEL`
```
NAME TYPE SIZE MOUNTPOINT FSTYPE MODEL
sdb disk ... | The sg\_\* utilities might also be useful:
```
$ sudo sg_map -i
/dev/sg0 /dev/sda ATA WDC WD5000BEVT-2 01.0
/dev/sg1 /dev/scd0 Optiarc BD ROM BC-5500S 1.83
/dev/sg2 /dev/sdb ATA WDC WD5000BEVT-0 01.0
/dev/sg3 /dev/sdc WD PP III Studio II 0817
```
There are lots of other commands in ... |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | Hope this helps:
```
<!DOCTYPE html>
<html lang="en">
<head>
<script src="jquery-1.12.2.js"></script>
</head>
<body>
<input class="txtOnly" id="txtOnly" name="txtOnly" type="text" />
<script>
$( document ).ready(function() {
$( ".txtOnly" ).keypress(func... | You could do using regex `/[^a-z]/g`
```js
$('.txtOnly').bind('keyup blur',function(){
var node = $(this);
node.val(node.val().replace(/[^a-z]/g,'') ); }
);
```
```html
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input name="lorem" class="txtOnly">
``` |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | You could do using regex `/[^a-z]/g`
```js
$('.txtOnly').bind('keyup blur',function(){
var node = $(this);
node.val(node.val().replace(/[^a-z]/g,'') ); }
);
```
```html
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input name="lorem" class="txtOnly">
``` | You may use following code snippet to prevent users from entering numeric input. It will check for each `keydown` event and prevent any subsequent action if numeric value is provided.
```js
$('.txtOnly').bind('keydown', function(event) {
var key = event.which;
if (key >=48 && key <= 57) {
event.preventDefau... |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | ```js
$('.txtOnly').keypress(function (e) {
var regex = new RegExp("^[a-zA-Z]+$");
var str = String.fromCharCode(!e.charCode ? e.which : e.charCode);
if (regex.test(str)) {
return true;
}
else
{
e.preventDefault();
$('.error').show();
$('.error').text('Please Enter Alphabate');
... | You could do using regex `/[^a-z]/g`
```js
$('.txtOnly').bind('keyup blur',function(){
var node = $(this);
node.val(node.val().replace(/[^a-z]/g,'') ); }
);
```
```html
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input name="lorem" class="txtOnly">
``` |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | Hope this helps:
```
<!DOCTYPE html>
<html lang="en">
<head>
<script src="jquery-1.12.2.js"></script>
</head>
<body>
<input class="txtOnly" id="txtOnly" name="txtOnly" type="text" />
<script>
$( document ).ready(function() {
$( ".txtOnly" ).keypress(func... | You may use following code snippet to prevent users from entering numeric input. It will check for each `keydown` event and prevent any subsequent action if numeric value is provided.
```js
$('.txtOnly').bind('keydown', function(event) {
var key = event.which;
if (key >=48 && key <= 57) {
event.preventDefau... |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | Hope this helps:
```
<!DOCTYPE html>
<html lang="en">
<head>
<script src="jquery-1.12.2.js"></script>
</head>
<body>
<input class="txtOnly" id="txtOnly" name="txtOnly" type="text" />
<script>
$( document ).ready(function() {
$( ".txtOnly" ).keypress(func... | ```js
$('.txtOnly').keypress(function (e) {
var regex = new RegExp("^[a-zA-Z]+$");
var str = String.fromCharCode(!e.charCode ? e.which : e.charCode);
if (regex.test(str)) {
return true;
}
else
{
e.preventDefault();
$('.error').show();
$('.error').text('Please Enter Alphabate');
... |
38,632,792 | I use the following JQuery function to restrict users from writing numeric values in the textbox. The code works fine but the problem is that it also restrict users from using other characters like full stop(.), comma(,), $, @ and other signs..It also does not allow users to use the options of copy and past. I only wan... | 2016/07/28 | [
"https://Stackoverflow.com/questions/38632792",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5588049/"
] | ```js
$('.txtOnly').keypress(function (e) {
var regex = new RegExp("^[a-zA-Z]+$");
var str = String.fromCharCode(!e.charCode ? e.which : e.charCode);
if (regex.test(str)) {
return true;
}
else
{
e.preventDefault();
$('.error').show();
$('.error').text('Please Enter Alphabate');
... | You may use following code snippet to prevent users from entering numeric input. It will check for each `keydown` event and prevent any subsequent action if numeric value is provided.
```js
$('.txtOnly').bind('keydown', function(event) {
var key = event.which;
if (key >=48 && key <= 57) {
event.preventDefau... |
5,437,501 | I have a concern of using GPL v2 and GPL v3 licensed software in commercial production environment. I would like to use HaProxy as a load balancing solution. Is it safe against copy-left? I won't modify anything from source code and the architecture of the system requires the use of a load balancer.
It will be embedde... | 2011/03/25 | [
"https://Stackoverflow.com/questions/5437501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/395146/"
] | If you're distributing (unmodified) binaries along with a product you ship, then you're required to distribute the source with them, or provide a way for people to request the sources. This is not a situation where you can ignore the GPL, but it's not going to be a real problem for you. The GPL won't infect your propri... | If you're not modifying the source and using the binaries, you should be entirely in the clear. |
5,437,501 | I have a concern of using GPL v2 and GPL v3 licensed software in commercial production environment. I would like to use HaProxy as a load balancing solution. Is it safe against copy-left? I won't modify anything from source code and the architecture of the system requires the use of a load balancer.
It will be embedde... | 2011/03/25 | [
"https://Stackoverflow.com/questions/5437501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/395146/"
] | Haproxy is GPLv2, so you can redistribute it in binary form provided you give enough information to the end user about where to fetch the sources to rebuild it. You also need to inform them about the build options / environment, because without them, it's possible that they won't be able to get the same features.
When... | If you're not modifying the source and using the binaries, you should be entirely in the clear. |
5,437,501 | I have a concern of using GPL v2 and GPL v3 licensed software in commercial production environment. I would like to use HaProxy as a load balancing solution. Is it safe against copy-left? I won't modify anything from source code and the architecture of the system requires the use of a load balancer.
It will be embedde... | 2011/03/25 | [
"https://Stackoverflow.com/questions/5437501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/395146/"
] | Another point about the title of your question "Can I use GPL software binaries in commercial environment?" : yes you can and you're even encouraged to do so. The more free software we'll have in commercial environments, the less hassle we'll have to fix issues in production ! | If you're not modifying the source and using the binaries, you should be entirely in the clear. |
5,437,501 | I have a concern of using GPL v2 and GPL v3 licensed software in commercial production environment. I would like to use HaProxy as a load balancing solution. Is it safe against copy-left? I won't modify anything from source code and the architecture of the system requires the use of a load balancer.
It will be embedde... | 2011/03/25 | [
"https://Stackoverflow.com/questions/5437501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/395146/"
] | If you're distributing (unmodified) binaries along with a product you ship, then you're required to distribute the source with them, or provide a way for people to request the sources. This is not a situation where you can ignore the GPL, but it's not going to be a real problem for you. The GPL won't infect your propri... | Haproxy is GPLv2, so you can redistribute it in binary form provided you give enough information to the end user about where to fetch the sources to rebuild it. You also need to inform them about the build options / environment, because without them, it's possible that they won't be able to get the same features.
When... |
5,437,501 | I have a concern of using GPL v2 and GPL v3 licensed software in commercial production environment. I would like to use HaProxy as a load balancing solution. Is it safe against copy-left? I won't modify anything from source code and the architecture of the system requires the use of a load balancer.
It will be embedde... | 2011/03/25 | [
"https://Stackoverflow.com/questions/5437501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/395146/"
] | If you're distributing (unmodified) binaries along with a product you ship, then you're required to distribute the source with them, or provide a way for people to request the sources. This is not a situation where you can ignore the GPL, but it's not going to be a real problem for you. The GPL won't infect your propri... | Another point about the title of your question "Can I use GPL software binaries in commercial environment?" : yes you can and you're even encouraged to do so. The more free software we'll have in commercial environments, the less hassle we'll have to fix issues in production ! |
21,212,121 | I am new to jquery, Please help me resolve the below issue.
I have a modal popup and inside the popup i have two asp buttons(Search and close). Onclick of the search button i want to perform a validation and then fire the server button click event and on click of the close button i want to close the dialog.
**Problem... | 2014/01/19 | [
"https://Stackoverflow.com/questions/21212121",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3211156/"
] | Add a constructor
```
template <typename Type2> Pos2(const Pos2<Type2> &other)
{ x = other.x; y = other.y; }
``` | You need to define an assignment operator for assignment from type `Size` to type `Pos`, because these are not the same type and therefore there is no default assignment operator between the two.
I guess you want to use a template here, so any instantiation of `Pos2` can be used to assign to another instantiation. For... |
47,350,199 | Environment:
Asp Net MVC app(.net framework 4.5.1) hosted on Azure app service with two instances.
App uses Azure SQL server database.
Also, app uses MemoryCache (System.Runtime.Caching) for caching purposes.
Recently, I noticed availability loss of the app. It happens almost every day.
[![enter image description here... | 2017/11/17 | [
"https://Stackoverflow.com/questions/47350199",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5841485/"
] | >
> What 'The memory counter Page Reads/sec' means?
>
>
>
We could get the answer from this [blog](https://www.sqlshack.com/sql-server-memory-performance-metrics-part-3-sql-server-buffer-manager-metrics-memory-counters/). The recommended Page reads/sec value should be under **90**. Higher values indicate **insuffi... | There is some memory performance problems can be listed
* excessive paging,
* memory shortages,
* memory leaks
Memory counter values can be used to detect the presence of various performance problems. Tracking counter values both on a **system-wide** and a **per-process** basis helps you to pinpoint the cause in Azur... |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | One possibility is [Calibre](http://calibre-ebook.com).
It is an ebook management program which permits conversion to various ebook formats but is cross-platform and can manage databases of pdf files (and not only).
If you decide to install I suggest you do so manually as the version in the repos is not very up to da... | **[Referencer](http://packages.ubuntu.com/de/lucid/referencer)** (GNOME) is a simple tool for managing document collections.
Tagging is possible.
It tries to find metadata on arXiv or via DOI, but you can add metadata manually too, of course.
But I guess development stopped. |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | One possibility is [Calibre](http://calibre-ebook.com).
It is an ebook management program which permits conversion to various ebook formats but is cross-platform and can manage databases of pdf files (and not only).
If you decide to install I suggest you do so manually as the version in the repos is not very up to da... | Have you Tried Gnome Documents?
>
> GNOME Documents is a standalone application to find, organize and view
> your documents.
>
>
>

[](https://apps.ubuntu.com/cat/applications/gnome-documents) |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | One possibility is [Calibre](http://calibre-ebook.com).
It is an ebook management program which permits conversion to various ebook formats but is cross-platform and can manage databases of pdf files (and not only).
If you decide to install I suggest you do so manually as the version in the repos is not very up to da... | I use Docear. Mind-mapping is the mode which I prefer to explore tagged (hierarchical) notes and references. The way they implement hierarchical node trees, it is effectively tagging.
The UI for building out mind maps is fast. Though there is some learning curve to overcome at the beginning, it pays off in spades when... |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | One possibility is [Calibre](http://calibre-ebook.com).
It is an ebook management program which permits conversion to various ebook formats but is cross-platform and can manage databases of pdf files (and not only).
If you decide to install I suggest you do so manually as the version in the repos is not very up to da... | Give I, Librarian a try:
<http://i-librarian.net>
It shows PDF covers, it allows tagging, it is web-based so network access is easy and fully cross-platform. |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | Have you Tried Gnome Documents?
>
> GNOME Documents is a standalone application to find, organize and view
> your documents.
>
>
>

[](https://apps.ubuntu.com/cat/applications/gnome-documents) | **[Referencer](http://packages.ubuntu.com/de/lucid/referencer)** (GNOME) is a simple tool for managing document collections.
Tagging is possible.
It tries to find metadata on arXiv or via DOI, but you can add metadata manually too, of course.
But I guess development stopped. |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | I use Docear. Mind-mapping is the mode which I prefer to explore tagged (hierarchical) notes and references. The way they implement hierarchical node trees, it is effectively tagging.
The UI for building out mind maps is fast. Though there is some learning curve to overcome at the beginning, it pays off in spades when... | **[Referencer](http://packages.ubuntu.com/de/lucid/referencer)** (GNOME) is a simple tool for managing document collections.
Tagging is possible.
It tries to find metadata on arXiv or via DOI, but you can add metadata manually too, of course.
But I guess development stopped. |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | Give I, Librarian a try:
<http://i-librarian.net>
It shows PDF covers, it allows tagging, it is web-based so network access is easy and fully cross-platform. | **[Referencer](http://packages.ubuntu.com/de/lucid/referencer)** (GNOME) is a simple tool for managing document collections.
Tagging is possible.
It tries to find metadata on arXiv or via DOI, but you can add metadata manually too, of course.
But I guess development stopped. |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | I use Docear. Mind-mapping is the mode which I prefer to explore tagged (hierarchical) notes and references. The way they implement hierarchical node trees, it is effectively tagging.
The UI for building out mind maps is fast. Though there is some learning curve to overcome at the beginning, it pays off in spades when... | Have you Tried Gnome Documents?
>
> GNOME Documents is a standalone application to find, organize and view
> your documents.
>
>
>

[](https://apps.ubuntu.com/cat/applications/gnome-documents) |
229,329 | I have a huge collection of PDF. Mostly it consists of research papers, of self-created documents but also of scanned documents.
Right now I drop them all in one folder and give them precise names with tags in the filename.
But even that gets impractical, so **I am looking for a PDF library management application**. ... | 2012/12/15 | [
"https://askubuntu.com/questions/229329",
"https://askubuntu.com",
"https://askubuntu.com/users/78383/"
] | I use Docear. Mind-mapping is the mode which I prefer to explore tagged (hierarchical) notes and references. The way they implement hierarchical node trees, it is effectively tagging.
The UI for building out mind maps is fast. Though there is some learning curve to overcome at the beginning, it pays off in spades when... | Give I, Librarian a try:
<http://i-librarian.net>
It shows PDF covers, it allows tagging, it is web-based so network access is easy and fully cross-platform. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.