qid int64 1 74.7M | question stringlengths 15 58.3k | date stringlengths 10 10 | metadata list | response_j stringlengths 4 30.2k | response_k stringlengths 11 36.5k |
|---|---|---|---|---|---|
18,902,873 | I'm testing creating reports with SQL Server. I've never used the reporting service before. I opened up "SQL Server Business Intelligence Development Studio" (which appears to be a stripped down version of Visual Studio 2008 with a different gui) and followed an msdn tutorial against some dummy data I dropped into a ta... | 2013/09/19 | [
"https://Stackoverflow.com/questions/18902873",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/868127/"
] | Using instertRow and insertCell:
```
function tableCreate(){
var body = document.body,
tbl = document.createElement('table');
tbl.style.width='100px';
tbl.style.border = "2px solid black";
for(var i = 0; i < 5; i++){
var tr = tbl.insertRow();
for(var j = 0; j < 4; j++){
if(i==2 && j==1){
... | Using JQuery it is extremely simple:
```
var table = $("#myTable tbody");
table.append("<tr><td>Element Column 1</td><td> Element Column 2 </td></tr>");
```
If you want to add a header dinamically, it is basically the same.
If you want to add CSS properties to all of your rows, for instance, you can use something l... |
18,902,873 | I'm testing creating reports with SQL Server. I've never used the reporting service before. I opened up "SQL Server Business Intelligence Development Studio" (which appears to be a stripped down version of Visual Studio 2008 with a different gui) and followed an msdn tutorial against some dummy data I dropped into a ta... | 2013/09/19 | [
"https://Stackoverflow.com/questions/18902873",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/868127/"
] | Using instertRow and insertCell:
```
function tableCreate(){
var body = document.body,
tbl = document.createElement('table');
tbl.style.width='100px';
tbl.style.border = "2px solid black";
for(var i = 0; i < 5; i++){
var tr = tbl.insertRow();
for(var j = 0; j < 4; j++){
if(i==2 && j==1){
... | ```
/*This is my javascript code to generate HTML table using recursion*/
//rowStart is starting index for row
var generateRowsWithCols = function(rowStart,noOfRows,noOfCols){
if(rowStart > noOfRows)
return;
var table = document.getElementById("grid");
var tr = table.insertRow("tr");
tr.set... |
38,376,422 | I am trying to create a Chocolatey package and was able to "choco pack" and "choco push" to a local chocolatey.server (simple server) repository. I have configured my `C:\ProgramData\Chocolatey\config\chocolatey.config` to point to my local chocolatey.server URL. When I try to run
```
choco install test1
```
I get t... | 2016/07/14 | [
"https://Stackoverflow.com/questions/38376422",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1442741/"
] | ### The Error
The error is telling you that you specified the `file` parameter more than once, which means you likely had one of the following:
* had `file` listed twice in your `$packageArgs`
* have specified `fileType` and `file` and called `Install-ChocolateyPackage`, which only has `filetype` (but PowerShell pass... | I was installing Redis and faced a similar issue, i managed to solve it by going to an old version [Deprecated], command :
```
choco install redis-64
```
So, the same may work for everyone else by just going to an older version i think. |
108,478 | i'm trying to play a video file but it says: 'there is no default application specified to open the document "vmt-pbboy-xvid.r02"' I was going to download xvid but it's not available for Mac, and i only have Mac computer. i don't know what to do? | 2010/02/13 | [
"https://superuser.com/questions/108478",
"https://superuser.com",
"https://superuser.com/users/18782/"
] | r02 is a RAR split archive, you will have to unpack the file, starting with the **first** archive (vmt-pbboy-xvid.rar).
You can use this program to extract the archive:
>
> **[UnRarX](http://www.unrarx.com/)** is a Mac OS X application that allows you to expand
> rar archives and restore corrupted or
> missing arc... | Looking at that filename I suspect the file is not a video - it looks to be part of a multi-part rar archive (which in turn contains the video file). You need to find all the other parts of the archive so you can extract its contents using a rar compatible archive tool. |
31,915,893 | My questions is: Can spring-boot application be created without Maven or Gradle support by keeping required jar files in classpath? | 2015/08/10 | [
"https://Stackoverflow.com/questions/31915893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5210465/"
] | Theoretically possible, but manually collecting the *correct versions* of the required JAR files seems impractical. In fact, one of the goal of Spring Boot is to maintain a list of *spring-boot-starters*, so that you can just use those in your build configuration file (like pom.xml), and the *correct version* of all th... | Yes if you have your own build system you can certainly gather all of the jars yourself and include them. Maven and Gradle both make it easier to get all of those jars and include tools for building the runnable jar file. |
3,396,364 | I have a regular expression that returns multiple variables within a match. I am interested in the first non-null variable in a subset of indices within the match, so I am using
```
result = a[1] || a[3] || a[6] || ...
```
I would like to store the relevant indices in a configuration file along with the regular expr... | 2010/08/03 | [
"https://Stackoverflow.com/questions/3396364",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/252348/"
] | Use `values_at` to get an array which contains only the elements at the specified indices. Then use `find {|x| x}` to get the first element that is not nil or false.
```
result = a.values_at(*indices).find {|x| x}
``` | Another way:
```
result = [1,3,6].find {|x| a[x]}
``` |
13,375,639 | I have a form with input like:
```
id="mytext" size="35"
```
This gives me a Box with 35 characters.
I want to have that with a Box of size 35 characters, but with 2 lines. how can I set that in HTML | 2012/11/14 | [
"https://Stackoverflow.com/questions/13375639",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1530845/"
] | Yes you do need the JDK.
For what it is worth, my Debian / Ubuntu package installs `openjdk-6-jdk` when building our `r-cran-rjava` package.
And it looks like the `java-1.6.0-openjdk.x86_64` package should work for you, you can also try `java-1.7.0-openjdk.x86_64`. | Earlier versions gives intermittent problem. Mirrors are not up-to-date, so go to the source at www.rforge.net: <http://www.rforge.net/rJava/files/>. Please use
`install.packages('rJava',,'http://www.rforge.net/')`
to install.”
That is almost correct. This actually works:
install.packages('rJava', .libPaths()[1], 'h... |
13,375,639 | I have a form with input like:
```
id="mytext" size="35"
```
This gives me a Box with 35 characters.
I want to have that with a Box of size 35 characters, but with 2 lines. how can I set that in HTML | 2012/11/14 | [
"https://Stackoverflow.com/questions/13375639",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1530845/"
] | Yes you do need the JDK.
For what it is worth, my Debian / Ubuntu package installs `openjdk-6-jdk` when building our `r-cran-rjava` package.
And it looks like the `java-1.6.0-openjdk.x86_64` package should work for you, you can also try `java-1.7.0-openjdk.x86_64`. | Try this it worked for me get over the configuration problem
<http://www.ibm.com/support/knowledgecenter/SSPT3X_3.0.0/com.ibm.swg.im.infosphere.biginsights.install.doc/doc/install_install_r.html>
I struggled installing rJava and had few learning. Let me explain.
When you issue the install package command in R
```
in... |
13,375,639 | I have a form with input like:
```
id="mytext" size="35"
```
This gives me a Box with 35 characters.
I want to have that with a Box of size 35 characters, but with 2 lines. how can I set that in HTML | 2012/11/14 | [
"https://Stackoverflow.com/questions/13375639",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1530845/"
] | Try this it worked for me get over the configuration problem
<http://www.ibm.com/support/knowledgecenter/SSPT3X_3.0.0/com.ibm.swg.im.infosphere.biginsights.install.doc/doc/install_install_r.html>
I struggled installing rJava and had few learning. Let me explain.
When you issue the install package command in R
```
in... | Earlier versions gives intermittent problem. Mirrors are not up-to-date, so go to the source at www.rforge.net: <http://www.rforge.net/rJava/files/>. Please use
`install.packages('rJava',,'http://www.rforge.net/')`
to install.”
That is almost correct. This actually works:
install.packages('rJava', .libPaths()[1], 'h... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | **head**
You use `head` with the `-n` option.
`head -n 10 FILE`
This will print the first ten lines of a file.
Another useful variation would be `-n -NUMBER`.
`head -n -10 FILE`
This will print all but the last ten lines of a file.
To solve your problem and get your desired output you can do the following.
```
... | This will do what you want, hopefuly:
```
find . -print -exec head {} -n 3 \;
```
`-print` will show the filename and the rest (from -`exec`) will show the first 3 lines of each file
Change the number according to your needs... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | You use the `head` command to do this, with the -n argument with the number of lines from each file, like this:
```
head -n3 *
```
or
```
head -n3 *.txt
```
This also works for a single file:
```
head -n3 filename.txt
``` | **head**
You use `head` with the `-n` option.
`head -n 10 FILE`
This will print the first ten lines of a file.
Another useful variation would be `-n -NUMBER`.
`head -n -10 FILE`
This will print all but the last ten lines of a file.
To solve your problem and get your desired output you can do the following.
```
... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | **head**
You use `head` with the `-n` option.
`head -n 10 FILE`
This will print the first ten lines of a file.
Another useful variation would be `-n -NUMBER`.
`head -n -10 FILE`
This will print all but the last ten lines of a file.
To solve your problem and get your desired output you can do the following.
```
... | To add the filename to the head output use 'head -v'. So 'head -vn 3 \*.html' gives me:
```
# head -vn 3 *.html
==> WebInfo.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
==> convert.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD ... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | You use the `head` command to do this, with the -n argument with the number of lines from each file, like this:
```
head -n3 *
```
or
```
head -n3 *.txt
```
This also works for a single file:
```
head -n3 filename.txt
``` | This will do what you want, hopefuly:
```
find . -print -exec head {} -n 3 \;
```
`-print` will show the filename and the rest (from -`exec`) will show the first 3 lines of each file
Change the number according to your needs... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | This will do what you want, hopefuly:
```
find . -print -exec head {} -n 3 \;
```
`-print` will show the filename and the rest (from -`exec`) will show the first 3 lines of each file
Change the number according to your needs... | To add the filename to the head output use 'head -v'. So 'head -vn 3 \*.html' gives me:
```
# head -vn 3 *.html
==> WebInfo.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
==> convert.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD ... |
29,056 | I have a folder with quite a few files in it. I want to display the following:
```
filename_1
first line of file1
second line of file1
third line of file1
filename_2
first line of file2
second line of file2
third line of file2
filename_3
first line of file3
second line of file3
third line of file3
```
etc. How can I... | 2011/03/04 | [
"https://askubuntu.com/questions/29056",
"https://askubuntu.com",
"https://askubuntu.com/users/6161/"
] | You use the `head` command to do this, with the -n argument with the number of lines from each file, like this:
```
head -n3 *
```
or
```
head -n3 *.txt
```
This also works for a single file:
```
head -n3 filename.txt
``` | To add the filename to the head output use 'head -v'. So 'head -vn 3 \*.html' gives me:
```
# head -vn 3 *.html
==> WebInfo.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
==> convert.html <==
<!DOCTYPE html PUBLIC "-//W3C//DTD ... |
15,776,799 | I have multiple projects with common in-house JavaScript library dependencies. I want to share these dependencies across multiple projects.
Unfortunately we are using TFS. I'd like something like svn:externals, whereby I can link a particular folder to a different folder elsewhere in the source control tree. So I want... | 2013/04/03 | [
"https://Stackoverflow.com/questions/15776799",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/83897/"
] | Just branch the shared project from its original location to where you want it to be.
When you would switch to next revision on svn:externals, simply merge changes up to that revision to the branched copy.
(frankly I prefer this way even on SVN) | Using external link in source is not a good idea. It creates lot of side effects. You can package and publish your library using NuGet to a private NuGet server and then consume the published packages in all the dependent projects. |
11,771,257 | I am trying to create a Media Foundation Transform that draws text on video using D2D and D3D11. I am trying to construct a D2D RenderTarget on top of D3D11 resources, but unfortunately, most means of D2D and D3D interop require D3D10, which is not available within this project.
The parameters I have to work with are... | 2012/08/02 | [
"https://Stackoverflow.com/questions/11771257",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/656298/"
] | Essentially you copy the frame from the input texture to the output texture, then do the following to retrieve an IDXGI surface:
```
IDXGISurface *surface;
pOutput->QueryInterface(&surface);
```
Then, follow the steps in [this tutorial](http://msdn.microsoft.com/en-us/library/windows/desktop/dd370966%28v=vs.85%29.as... | Do you create a swap chain? You could creat one with IDXGIFactory2::CreateSwapChainForCoreWindow or CreateSwapChainForComposition if you use XAML UI. Then after you render your d3d stuff, you can creat d2d target and render on top just like in this d3d tutorial sample, look for "sampleOverlay.cpp"
<http://code.msdn.mi... |
11,771,257 | I am trying to create a Media Foundation Transform that draws text on video using D2D and D3D11. I am trying to construct a D2D RenderTarget on top of D3D11 resources, but unfortunately, most means of D2D and D3D interop require D3D10, which is not available within this project.
The parameters I have to work with are... | 2012/08/02 | [
"https://Stackoverflow.com/questions/11771257",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/656298/"
] | I met the same problem before, it's depende on which system you are runing.
1. On Windows 7, only Direct3D 10 support interoperate with Direct2D
2. On Windows 8, Direct2D can interoperate with Direct3D 11 | Do you create a swap chain? You could creat one with IDXGIFactory2::CreateSwapChainForCoreWindow or CreateSwapChainForComposition if you use XAML UI. Then after you render your d3d stuff, you can creat d2d target and render on top just like in this d3d tutorial sample, look for "sampleOverlay.cpp"
<http://code.msdn.mi... |
62,962,732 | I am validating a contact form. I wrapped it in a div with the id of "contactform". When validation messages appear after submission I want the redirected page to scroll down automatically to the "contactform" div so users don't have to scroll down themselves to correct the form.
I can accomplish this easily by manual... | 2020/07/17 | [
"https://Stackoverflow.com/questions/62962732",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10836979/"
] | As mentioned in the comments by @cel uninstalling and reinstalling numpy using `pip uninstall numpy` and `pip install numpy` made it work. | Open the Anaconda Prompt:
Then, you have to go to the Conda Environment that you want to use in PowerBI. Am having an environment 'temp', so I activate it first in the 'Anaconda Prompt':
```
(base) C:\Users\ashish>conda activate temp
```
Then I go to the directory having the "PowerBI" executable file in the installa... |
62,962,732 | I am validating a contact form. I wrapped it in a div with the id of "contactform". When validation messages appear after submission I want the redirected page to scroll down automatically to the "contactform" div so users don't have to scroll down themselves to correct the form.
I can accomplish this easily by manual... | 2020/07/17 | [
"https://Stackoverflow.com/questions/62962732",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10836979/"
] | As mentioned in the comments by @cel uninstalling and reinstalling numpy using `pip uninstall numpy` and `pip install numpy` made it work. | I better way is to
```
import os
import sys
os.path.dirname(sys.executable)
```
This will give you the path to your environment. Put the path into the settings for python |
62,962,732 | I am validating a contact form. I wrapped it in a div with the id of "contactform". When validation messages appear after submission I want the redirected page to scroll down automatically to the "contactform" div so users don't have to scroll down themselves to correct the form.
I can accomplish this easily by manual... | 2020/07/17 | [
"https://Stackoverflow.com/questions/62962732",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10836979/"
] | I better way is to
```
import os
import sys
os.path.dirname(sys.executable)
```
This will give you the path to your environment. Put the path into the settings for python | Open the Anaconda Prompt:
Then, you have to go to the Conda Environment that you want to use in PowerBI. Am having an environment 'temp', so I activate it first in the 'Anaconda Prompt':
```
(base) C:\Users\ashish>conda activate temp
```
Then I go to the directory having the "PowerBI" executable file in the installa... |
7,445 | I've baked my first pita bread in home, the pockets was almost well formed but the crust is hard, crunchy.
I've applied some variations because of time/number/ingredients restrictions, in particular:
* I've used two part of white flour (farina 00) and one part of whole-wheat flour
* I've made the pitas a bit thin, sa... | 2010/09/19 | [
"https://cooking.stackexchange.com/questions/7445",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/1805/"
] | Cook only until it is fully puffed. If that isn't enough, try folding them right after taking them out, and put them in a paper bag. They'll steam themselves briefly and keep the crust soft. | Try lowering your oven temperature by 25 degrees at a time, and/or shortening how long you cook it until just lightly browned. |
7,445 | I've baked my first pita bread in home, the pockets was almost well formed but the crust is hard, crunchy.
I've applied some variations because of time/number/ingredients restrictions, in particular:
* I've used two part of white flour (farina 00) and one part of whole-wheat flour
* I've made the pitas a bit thin, sa... | 2010/09/19 | [
"https://cooking.stackexchange.com/questions/7445",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/1805/"
] | Cook only until it is fully puffed. If that isn't enough, try folding them right after taking them out, and put them in a paper bag. They'll steam themselves briefly and keep the crust soft. | We cook our pitas on the stovetop on a very hot cast iron skillet. You can monitor each pita carefully that way. Put the pita in the pan and flip it when it puffs. You can encourage the small puff bubbles to join by gently pushing down on them with a spatula. Once the pan is hot, each pita only takes about 2 minutes. |
29,647,168 | I'm working on PHP at the moment.
I have a form seen below with a submit button.
I then created a function below also.
As you can see the first thing the function does is checked the submit button is pressed, but it goes into this if upon loading the page(i don't need to press the button), and it out puts the "Entry S... | 2015/04/15 | [
"https://Stackoverflow.com/questions/29647168",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4312706/"
] | You should try to preload the image first:
```
var img = new Image()
img.onload = function() {
// gets called when the img is loaded
};
img.src = 'img.png';
```
Keep in mind, that the onload function is called when the image is loaded, so it's async. | You can use Bitmap.getBounds().width |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | Xanthan gum may be more expensive than you like, but consider that you so VERY LITTLE of it that it will last a long, long time. There's a reason why it's used in industrial production so much, I think -- it's very cost effective. | This will need to be tested, but what about ground chia seeds? If you put whole chia in water (or juice/smoothie) the seed coats plump up and are a tad gelatinous. They do not alter the flavor of drinks in my opinion. |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | Xanthan gum may be more expensive than you like, but consider that you so VERY LITTLE of it that it will last a long, long time. There's a reason why it's used in industrial production so much, I think -- it's very cost effective. | Hot Chocolate is lovely Mexican style: thickened with fine corn meal -masa harina. Velvety texture without the fat
Masa is also easy to stir in as it doesn't clump as badly as flour. Thickens below the boiling point. |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | Xanthan gum may be more expensive than you like, but consider that you so VERY LITTLE of it that it will last a long, long time. There's a reason why it's used in industrial production so much, I think -- it's very cost effective. | I like using Irish moss (the plant that carrageenan is made from) to thicken cold beverages. It is a bit expensive to buy, but you need very little, so the cost per use is quite low. To use it, you soak a piece of the plant in water overnight, then puree it in a blender until it's as smooth as you can get it. Strain ou... |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | If you are talking about the Bolthouse Farms Vanilla Chai Tea, the problem you are running into is that its actually a blend of a plain chai tea and a lightly vanilla flavored soy protein blend. I have tried a few times myself to duplicate it and i came up with this...
* I would make a good hot chai and mix it with va... | This will need to be tested, but what about ground chia seeds? If you put whole chia in water (or juice/smoothie) the seed coats plump up and are a tad gelatinous. They do not alter the flavor of drinks in my opinion. |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | If you are talking about the Bolthouse Farms Vanilla Chai Tea, the problem you are running into is that its actually a blend of a plain chai tea and a lightly vanilla flavored soy protein blend. I have tried a few times myself to duplicate it and i came up with this...
* I would make a good hot chai and mix it with va... | Hot Chocolate is lovely Mexican style: thickened with fine corn meal -masa harina. Velvety texture without the fat
Masa is also easy to stir in as it doesn't clump as badly as flour. Thickens below the boiling point. |
23,392 | I need a vegan thickener that dissolves well and doesn't have any flavor. I tried tapioca flour the other day and it didn't dissolve very well and left a powdery mouthfeel. Cornstach is not bad. Arrowroot seems to work like cornstarch but it seems like you need more arrowroot to do the same job as cornstarch.
I'm spec... | 2012/04/27 | [
"https://cooking.stackexchange.com/questions/23392",
"https://cooking.stackexchange.com",
"https://cooking.stackexchange.com/users/5776/"
] | If you are talking about the Bolthouse Farms Vanilla Chai Tea, the problem you are running into is that its actually a blend of a plain chai tea and a lightly vanilla flavored soy protein blend. I have tried a few times myself to duplicate it and i came up with this...
* I would make a good hot chai and mix it with va... | I like using Irish moss (the plant that carrageenan is made from) to thicken cold beverages. It is a bit expensive to buy, but you need very little, so the cost per use is quite low. To use it, you soak a piece of the plant in water overnight, then puree it in a blender until it's as smooth as you can get it. Strain ou... |
22,911,893 | I have pointed my location in google map using mapmaker.My company name is VK Academy It solutions.my question is how do i point to my website..... I want to know how to do in java script and php | 2014/04/07 | [
"https://Stackoverflow.com/questions/22911893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3506619/"
] | To monitor if there's a memory leak in .NEE, you can just use Windows Performance Monitor. From this article: [Identify And Prevent Memory Leaks In Managed Code](http://msdn.microsoft.com/en-us/magazine/cc163491.aspx):
Use PerfMon to examine the following performance counters for the application: Process/Private Byte... | *"If you suspect there is a user-mode memory leak but are not sure which process is causing it, you can use Performance Monitor to measure the memory usage of individual processes."*
See <http://msdn.microsoft.com/en-us/library/windows/hardware/ff560134(v=vs.85).aspx> |
22,911,893 | I have pointed my location in google map using mapmaker.My company name is VK Academy It solutions.my question is how do i point to my website..... I want to know how to do in java script and php | 2014/04/07 | [
"https://Stackoverflow.com/questions/22911893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3506619/"
] | To monitor if there's a memory leak in .NEE, you can just use Windows Performance Monitor. From this article: [Identify And Prevent Memory Leaks In Managed Code](http://msdn.microsoft.com/en-us/magazine/cc163491.aspx):
Use PerfMon to examine the following performance counters for the application: Process/Private Byte... | Use a memory profiler, like ANTS Memory Profiler or EQATEC |
22,911,893 | I have pointed my location in google map using mapmaker.My company name is VK Academy It solutions.my question is how do i point to my website..... I want to know how to do in java script and php | 2014/04/07 | [
"https://Stackoverflow.com/questions/22911893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3506619/"
] | To monitor if there's a memory leak in .NEE, you can just use Windows Performance Monitor. From this article: [Identify And Prevent Memory Leaks In Managed Code](http://msdn.microsoft.com/en-us/magazine/cc163491.aspx):
Use PerfMon to examine the following performance counters for the application: Process/Private Byte... | I advise you to use [`CLR Profiler`](http://www.microsoft.com/en-us/download/details.aspx?id=16273), it's free and freely distributable application:
>
> The primary function of `CLR Profiler` is to enable you to understand how your application interacts with the managed, garbage-collected heap. Some of the more impor... |
22,911,893 | I have pointed my location in google map using mapmaker.My company name is VK Academy It solutions.my question is how do i point to my website..... I want to know how to do in java script and php | 2014/04/07 | [
"https://Stackoverflow.com/questions/22911893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3506619/"
] | To monitor if there's a memory leak in .NEE, you can just use Windows Performance Monitor. From this article: [Identify And Prevent Memory Leaks In Managed Code](http://msdn.microsoft.com/en-us/magazine/cc163491.aspx):
Use PerfMon to examine the following performance counters for the application: Process/Private Byte... | Next to ANTS or EQATEC you also have JetBrains dotTrace.
Also if you don't want to use a profiler, you could go through your code and look for disposable objects. Every disposable object should be disposed off when it's usage came to an end.
In most cases if you've disposed of all your objects in a correct way you won'... |
22,911,893 | I have pointed my location in google map using mapmaker.My company name is VK Academy It solutions.my question is how do i point to my website..... I want to know how to do in java script and php | 2014/04/07 | [
"https://Stackoverflow.com/questions/22911893",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3506619/"
] | To monitor if there's a memory leak in .NEE, you can just use Windows Performance Monitor. From this article: [Identify And Prevent Memory Leaks In Managed Code](http://msdn.microsoft.com/en-us/magazine/cc163491.aspx):
Use PerfMon to examine the following performance counters for the application: Process/Private Byte... | You may try out [`Coverity`](http://www.coverity.com/). They find defects that includes:
* Memory Corruption
* Crashes
* Security Vulnerabilities
* Concurrency
* Uninitialized memory
* Error handling
* Resource leaks
You may find more [here](http://www.coverity.com/why-coverity/#Developers). |
11,178,481 | I state that I am a complete beginner to LDAP.
I have to let a user change its own password through an Android device. User has NOT administrative privileges.
Using the [UnboudId LDAP SDK](http://www.unboundid.com/products/ldap-sdk) for Java I'm able to bind to server and get the user entry using this code:
```... | 2012/06/24 | [
"https://Stackoverflow.com/questions/11178481",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/520032/"
] | ```
final Modification _delete_old_modification = new Modification(ModificationType.DELETE, "unicodePwd", ('"' + oldPassword + '"').getBytes("UTF-16LE"));
final Modification _add_new_modification = new Modification(ModificationType.ADD, "unicodePwd", ('"' + newPassword + '"').getBytes("UTF-16LE"));
```
Did the trick. | Finally, I was able to resolve CONSTRAINT\_ATT\_TYPE issue in password change. I had set minimum password age as 4 days, so AD wasn’t allowing me to update the password. AD throws generic error CONSTRAINT\_ATT\_TYPE for all such violations. After setting minimum password age as 0 (None), everything works fine. AD passw... |
11,178,481 | I state that I am a complete beginner to LDAP.
I have to let a user change its own password through an Android device. User has NOT administrative privileges.
Using the [UnboudId LDAP SDK](http://www.unboundid.com/products/ldap-sdk) for Java I'm able to bind to server and get the user entry using this code:
```... | 2012/06/24 | [
"https://Stackoverflow.com/questions/11178481",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/520032/"
] | ```
final Modification _delete_old_modification = new Modification(ModificationType.DELETE, "unicodePwd", ('"' + oldPassword + '"').getBytes("UTF-16LE"));
final Modification _add_new_modification = new Modification(ModificationType.ADD, "unicodePwd", ('"' + newPassword + '"').getBytes("UTF-16LE"));
```
Did the trick. | "Minimum password age" was the source of my problem CONSTRAINT\_ATT\_TYPE |
66,680,288 | I wanna get the count of occurrences when the data in column 1 is 1 and also data in column 2 is 1. TIA
 | 2021/03/17 | [
"https://Stackoverflow.com/questions/66680288",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14722743/"
] | You can use `filter` and `summarize` from `dplyr` package
```
library(dplyr)
df1 <- df %>%
filter(col1 == 1 & col2==1) %>%
summarize(Freq_col1andcol2_equalto1 = n())
```
data:
```
df <- tribble(
~col1, ~col2,
5,5,
5,5,
1,1,
5,5,
5,5)
``` | ```
seed(323)
df <- tibble(x = round(runif(100, 0, 10)),
y = round(runif(100, 0, 10)))
df %>% count(x==1,y==1)
# A tibble: 4 x 3
# `x == 1` `y == 1` n
# <lgl> <lgl> <int>
# 1 FALSE FALSE 80
# 2 FALSE TRUE 10
# 3 TRUE FALSE 8
# 4 TRUE TRUE 2
```
I... |
43,299,423 | I have this situation: I want to download a bunch of files named like this:
```
683482, 684483, 685484, 686485, 687486, 688487, 689488, 690489, 691490, 692491, ...
```
As you can see, the files are numbered with an increment of 1001. So, what's the easiest way to do a batch download? | 2017/04/08 | [
"https://Stackoverflow.com/questions/43299423",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7704786/"
] | `fadeToggle` works the same way as e.g. `toggle` (applies opposed attribute). And since the default state for the `p` element at the begininng is `display: inline` (is visible), then the next default action will be hiding it. That's why you have to define it initially as hidden.
```js
$(document).ready(function() {
... | It works correctly actually - the paragraph element is shown and by clicking on the heading, the function inserts text in it and then toggles fade. As the element is shown, by default (since there are no rules attached to it that would otherwise hide it), the fadeToggle will transition from shown to hidden state.
As s... |
35,305,997 | In my settings.py I have this:
```
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'foo',
'USER': 'foo',
'PASSWORD': 'foo',
'HOST': 'localhost',
},
}
```
I've ran this SQL on my db:
```
GRANT ALL ON test_foo.* TO 'foo'@'localhost';
```
I've distilled what I'm t... | 2016/02/10 | [
"https://Stackoverflow.com/questions/35305997",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4080713/"
] | Django's `TestCase` class makes use of database transactions (if the database supports it) to speed up tests.
This means that within a test method, any database modifications is only visible to that test and is not committed to the database. You won't be able to inspect the changes using an external tool.
If you nee... | <https://docs.djangoproject.com/en/1.9/topics/testing/overview/#the-test-database>
>
> Tests that require a database (namely, model tests) will not use your “real” (production) database. Separate, blank databases are created for the tests.
>
>
>
The default database name starts with `test_`, per the docs linked a... |
131,943 | Suppose an entity from a higher dimensions who can experience time flowing both forward and backward wants to understand our world and how far humanity have advanced in tech and science, is it possible to explain entropy to them since I suspect that it will be similar to telling them about a solid wall when there is an... | 2018/12/04 | [
"https://worldbuilding.stackexchange.com/questions/131943",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/8400/"
] | It shouldn't be too hard in practice.
Consider that you're having a conversation with one of these beings. It'll take a while for them to work out what's going on, but once they understand that they have to jog along at a steady pace in time to be able to communicate with you, they'll understand a lot more about our p... | Sure, you simply describe it according to it's time axis. You give it point 1 (now) and point 2 (again, now, but the later now than before). Now you can calculate a vector from point 1 to point 2, that is the positive direction of time.
So then you change the scalar of time in the thermodynamic equations for the vecto... |
131,943 | Suppose an entity from a higher dimensions who can experience time flowing both forward and backward wants to understand our world and how far humanity have advanced in tech and science, is it possible to explain entropy to them since I suspect that it will be similar to telling them about a solid wall when there is an... | 2018/12/04 | [
"https://worldbuilding.stackexchange.com/questions/131943",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/8400/"
] | Sure, you simply describe it according to it's time axis. You give it point 1 (now) and point 2 (again, now, but the later now than before). Now you can calculate a vector from point 1 to point 2, that is the positive direction of time.
So then you change the scalar of time in the thermodynamic equations for the vecto... | This being might have already observed that for some reason unknown to him all things in our world move always and only in one direction in the dimension we call time.
Explain that entropy is what defines the direction of time: "we" can only move in the direction where the entropy increases. So we can let a bottle of ... |
131,943 | Suppose an entity from a higher dimensions who can experience time flowing both forward and backward wants to understand our world and how far humanity have advanced in tech and science, is it possible to explain entropy to them since I suspect that it will be similar to telling them about a solid wall when there is an... | 2018/12/04 | [
"https://worldbuilding.stackexchange.com/questions/131943",
"https://worldbuilding.stackexchange.com",
"https://worldbuilding.stackexchange.com/users/8400/"
] | It shouldn't be too hard in practice.
Consider that you're having a conversation with one of these beings. It'll take a while for them to work out what's going on, but once they understand that they have to jog along at a steady pace in time to be able to communicate with you, they'll understand a lot more about our p... | This being might have already observed that for some reason unknown to him all things in our world move always and only in one direction in the dimension we call time.
Explain that entropy is what defines the direction of time: "we" can only move in the direction where the entropy increases. So we can let a bottle of ... |
41,549,154 | I have a `Person` model with `name` and `city` as attributes. I need a way to retrieve the amount of people by city. I need an output like this dictionary: `{"NY": 23, "CA": 30, ...}`
What I did was:
```
response = {}
for city in ["NY", "CA", ...]:
response[city] = Person.objects.filter(city=city).count()
```
H... | 2017/01/09 | [
"https://Stackoverflow.com/questions/41549154",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6016582/"
] | 1) One process could easily use all the cores/hyperthreads available on your processor, by simply spawning multiple threads or processes and making them perform any kind of computation (for example, an infinite loop). The kernel's scheduler will typically try to spread the load on all the available resources
2) I am n... | 1) A process's threads can run in parallel in multiple CPUs/cores. Multi-threading wouldn't be nearly so useful if only one thread could run at a time! By default the kernel can and will schedule a thread on any available core. Other threads, even if part of the same process, running on another core makes no difference... |
1,484,426 | To show that the series $\sum\_{k=1}^{\infty} {{1}\over {k}}$ diverges ; I have to prove that $${\sum\_{k=1}^{n}}{{1}\over{k}} \ge {\log n}$$ The given hint is that $${{1}\over {k}}\ge \int\_k^{k+1} {1\over x} dx$$
Now,evaluating the RHS, say $$L=\int\_k^{k+1} {1\over x} dx\\=\log(k+1)-\log\ k\\=\log(1+{1\over k})\\={... | 2015/10/17 | [
"https://math.stackexchange.com/questions/1484426",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/118494/"
] | $$\begin{align}\frac 1k&\geq\int\_k^{k+1} \frac 1xdx\\
\text{Sum from $k=1$ to $n$:}&\\
\sum\_{k=1}^n\frac 1k&\geq \sum\_{k=1}^n\int\_k^{k+1}\frac 1xdx=\int\_1^{n+1}\frac 1xdx=\log(n+1)\geq\log n \\
\sum\_{k=1}^n\frac 1k&\geq\log n\quad\blacksquare
\end{align}$$ | Hint: Use the telescopic nature of the expression $\log(k+1)-\log(k)$.
For example when $n=3$, you have shown that
$\frac{1}{1}+\frac{1}{2}+\frac{1}{3} \geq \log(2)-\log(1)+\log(3)-\log(2)+\log(4)-\log(3) = \log(4)-\log(1)$.
Take the limit as $n \to \infty$ and observe the expression on the right hand side of the i... |
1,484,426 | To show that the series $\sum\_{k=1}^{\infty} {{1}\over {k}}$ diverges ; I have to prove that $${\sum\_{k=1}^{n}}{{1}\over{k}} \ge {\log n}$$ The given hint is that $${{1}\over {k}}\ge \int\_k^{k+1} {1\over x} dx$$
Now,evaluating the RHS, say $$L=\int\_k^{k+1} {1\over x} dx\\=\log(k+1)-\log\ k\\=\log(1+{1\over k})\\={... | 2015/10/17 | [
"https://math.stackexchange.com/questions/1484426",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/118494/"
] | $$\begin{align}\frac 1k&\geq\int\_k^{k+1} \frac 1xdx\\
\text{Sum from $k=1$ to $n$:}&\\
\sum\_{k=1}^n\frac 1k&\geq \sum\_{k=1}^n\int\_k^{k+1}\frac 1xdx=\int\_1^{n+1}\frac 1xdx=\log(n+1)\geq\log n \\
\sum\_{k=1}^n\frac 1k&\geq\log n\quad\blacksquare
\end{align}$$ | **Hint** $k \leq x \leq k+1$ thus $\frac{1}{x} \leq \frac{1}{k}$.
$$L=\int\_k^{k+1} {1\over x} dx \leq \int\_k^{k+1} {1\over k} dx$$ |
1,484,426 | To show that the series $\sum\_{k=1}^{\infty} {{1}\over {k}}$ diverges ; I have to prove that $${\sum\_{k=1}^{n}}{{1}\over{k}} \ge {\log n}$$ The given hint is that $${{1}\over {k}}\ge \int\_k^{k+1} {1\over x} dx$$
Now,evaluating the RHS, say $$L=\int\_k^{k+1} {1\over x} dx\\=\log(k+1)-\log\ k\\=\log(1+{1\over k})\\={... | 2015/10/17 | [
"https://math.stackexchange.com/questions/1484426",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/118494/"
] | $$\begin{align}\frac 1k&\geq\int\_k^{k+1} \frac 1xdx\\
\text{Sum from $k=1$ to $n$:}&\\
\sum\_{k=1}^n\frac 1k&\geq \sum\_{k=1}^n\int\_k^{k+1}\frac 1xdx=\int\_1^{n+1}\frac 1xdx=\log(n+1)\geq\log n \\
\sum\_{k=1}^n\frac 1k&\geq\log n\quad\blacksquare
\end{align}$$ | $$\prod\_{k=1}^{n-1}\left(1+\frac{1}{k}\right)=\prod\_{k=1}^{n-1}\left(\frac{k+1}{k}\right)=n $$
hence by taking logs and exploiting $\log(1+x)\leq x$ for $|x|<1$ we have:
$$ \log(n) = \sum\_{k=1}^{n-1}\log\left(1+\frac{1}{k}\right) \leq \sum\_{k=1}^{n-1}\frac{1}{k} $$
so $H\_n>\log(n)$. |
1,484,426 | To show that the series $\sum\_{k=1}^{\infty} {{1}\over {k}}$ diverges ; I have to prove that $${\sum\_{k=1}^{n}}{{1}\over{k}} \ge {\log n}$$ The given hint is that $${{1}\over {k}}\ge \int\_k^{k+1} {1\over x} dx$$
Now,evaluating the RHS, say $$L=\int\_k^{k+1} {1\over x} dx\\=\log(k+1)-\log\ k\\=\log(1+{1\over k})\\={... | 2015/10/17 | [
"https://math.stackexchange.com/questions/1484426",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/118494/"
] | $$\begin{align}\frac 1k&\geq\int\_k^{k+1} \frac 1xdx\\
\text{Sum from $k=1$ to $n$:}&\\
\sum\_{k=1}^n\frac 1k&\geq \sum\_{k=1}^n\int\_k^{k+1}\frac 1xdx=\int\_1^{n+1}\frac 1xdx=\log(n+1)\geq\log n \\
\sum\_{k=1}^n\frac 1k&\geq\log n\quad\blacksquare
\end{align}$$ | The map $x \mapsto 1/x$ is stricly decreasing and the map $\log$ is strictly increasing , implying that for every $n \geq 1$ we have
$$
\sum\_{k=1}^{n}\frac{1}{k} \geq \int\_{x = 1}^{n+1}\frac{1}{x} = \log (n+1) > \log (n).
$$ |
384,697 | Show btn is working for this parent to child communication. how to hide the child comp. with same btn??
```
import { LightningElement, track } from "lwc";
export default class ParentComp extends LightningElement {
@track onClickButtonLabel = "Show";
startCounter = 0;
handleStartChange(event) {
this.startCou... | 2022/09/06 | [
"https://salesforce.stackexchange.com/questions/384697",
"https://salesforce.stackexchange.com",
"https://salesforce.stackexchange.com/users/121664/"
] | You can use an aggregate SOQL query for this, and then only return accounts that have more than 1 asset with that status:
```
SELECT AccountId , count(Id) FROM Asset WHERE Status = 'X' GROUP BY AccountId HAVING Count(AccountId) > 1
```
<https://developer.salesforce.com/docs/atlas.en-us.236.0.soql_sosl.meta/soql_sosl... | Try something like 1 or 2:
1.
```sql
SELECT AccountId FROM Asset WHERE Status = 'X' GROUP BY AccountId
```
2.
```sql
SELECT Id, (SELECT Id FROM Assets WHERE Status = 'X') FROM Account
``` |
163,288 | Most of the questions on MSE about educational resources are for high school. At least I haven't found questions which deals with sites on very elementary mathematics.
I will be grateful if someone provides me with list of educational resources for kids - e.g. of the level of kindergarten, primary school and junior h... | 2012/06/26 | [
"https://math.stackexchange.com/questions/163288",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/19538/"
] | Here are some things I found in a few minutes. I'm also including what seemed to be the best google search among those I tried.
Google search for [“elementary school” mathematics resources links](https://www.google.com/search?q=%22elementary%20school%22%20mathematics%20resources%20links&gws_rd=ssl)
[Math Archives: K-... | Though not a direct answer to your question, another resource you may be able to use is a university sponsored Math Circle program. They really are amazing and I am extremely jealous of those kids (I wish I got to go to a Math Circle when I was their age!). If you're not familiar with what it is, it's basically a progr... |
163,288 | Most of the questions on MSE about educational resources are for high school. At least I haven't found questions which deals with sites on very elementary mathematics.
I will be grateful if someone provides me with list of educational resources for kids - e.g. of the level of kindergarten, primary school and junior h... | 2012/06/26 | [
"https://math.stackexchange.com/questions/163288",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/19538/"
] | Here are some things I found in a few minutes. I'm also including what seemed to be the best google search among those I tried.
Google search for [“elementary school” mathematics resources links](https://www.google.com/search?q=%22elementary%20school%22%20mathematics%20resources%20links&gws_rd=ssl)
[Math Archives: K-... | WGBH has launched an all-new bilingual [Web site](http://peepandthebigwideworld.com/en/) and curriculum for PEEP and the Big Wide World, the Emmy Award-winning preschool science and math series for 3-5 year olds.
TenMarks Education has a professional development, preparatory, and in-class resource for teachers. The... |
163,288 | Most of the questions on MSE about educational resources are for high school. At least I haven't found questions which deals with sites on very elementary mathematics.
I will be grateful if someone provides me with list of educational resources for kids - e.g. of the level of kindergarten, primary school and junior h... | 2012/06/26 | [
"https://math.stackexchange.com/questions/163288",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/19538/"
] | Here are some things I found in a few minutes. I'm also including what seemed to be the best google search among those I tried.
Google search for [“elementary school” mathematics resources links](https://www.google.com/search?q=%22elementary%20school%22%20mathematics%20resources%20links&gws_rd=ssl)
[Math Archives: K-... | For Kindergarten and elementary school you should check out [ClassK12](http://www.classk12.com)
which comprehensively covers the curriculum in a fun interactive format. |
163,288 | Most of the questions on MSE about educational resources are for high school. At least I haven't found questions which deals with sites on very elementary mathematics.
I will be grateful if someone provides me with list of educational resources for kids - e.g. of the level of kindergarten, primary school and junior h... | 2012/06/26 | [
"https://math.stackexchange.com/questions/163288",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/19538/"
] | Though not a direct answer to your question, another resource you may be able to use is a university sponsored Math Circle program. They really are amazing and I am extremely jealous of those kids (I wish I got to go to a Math Circle when I was their age!). If you're not familiar with what it is, it's basically a progr... | WGBH has launched an all-new bilingual [Web site](http://peepandthebigwideworld.com/en/) and curriculum for PEEP and the Big Wide World, the Emmy Award-winning preschool science and math series for 3-5 year olds.
TenMarks Education has a professional development, preparatory, and in-class resource for teachers. The... |
163,288 | Most of the questions on MSE about educational resources are for high school. At least I haven't found questions which deals with sites on very elementary mathematics.
I will be grateful if someone provides me with list of educational resources for kids - e.g. of the level of kindergarten, primary school and junior h... | 2012/06/26 | [
"https://math.stackexchange.com/questions/163288",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/19538/"
] | Though not a direct answer to your question, another resource you may be able to use is a university sponsored Math Circle program. They really are amazing and I am extremely jealous of those kids (I wish I got to go to a Math Circle when I was their age!). If you're not familiar with what it is, it's basically a progr... | For Kindergarten and elementary school you should check out [ClassK12](http://www.classk12.com)
which comprehensively covers the curriculum in a fun interactive format. |
41,822 | My bank offers 11% interest rate for 1-year deposit in USD. This is similar to what other Ukrainian banks offer but much higher in comparison with our neighboring countries, Belarus (3.5%) and Poland (1.8%). In the US it seems to be even lower at .2%.
Why is it so different from country to country? Is it all about the... | 2015/01/02 | [
"https://money.stackexchange.com/questions/41822",
"https://money.stackexchange.com",
"https://money.stackexchange.com/users/20113/"
] | This is just a guess but I would imagine that it has to do with risk. The deposits in Banks are usually as safe as government bonds (broad oversimplification) as:
* Usually bank deposits are insured by local equivalent of FDIC. I'm not sure about local regulation but it means that they are backed partially by the gove... | It may seem weird but interest rates are set by a market. Risk is a very large component of the price that a saver will accept to deposit their money in a bank but not the only one.
Essentially you are "lending" deposited cash to the bank that you put it in and they will lend it out at a certain risk to themselves and... |
41,822 | My bank offers 11% interest rate for 1-year deposit in USD. This is similar to what other Ukrainian banks offer but much higher in comparison with our neighboring countries, Belarus (3.5%) and Poland (1.8%). In the US it seems to be even lower at .2%.
Why is it so different from country to country? Is it all about the... | 2015/01/02 | [
"https://money.stackexchange.com/questions/41822",
"https://money.stackexchange.com",
"https://money.stackexchange.com/users/20113/"
] | This is just a guess but I would imagine that it has to do with risk. The deposits in Banks are usually as safe as government bonds (broad oversimplification) as:
* Usually bank deposits are insured by local equivalent of FDIC. I'm not sure about local regulation but it means that they are backed partially by the gove... | I concur with the answers above - the difference is about the risk. But in this particular case I find the interest level implausible. 11% interest on deposits in USD seems very speculative and unsustainable. You can't guarantee such return on investment unless you engage in drug trade or some other illegal activity. O... |
41,822 | My bank offers 11% interest rate for 1-year deposit in USD. This is similar to what other Ukrainian banks offer but much higher in comparison with our neighboring countries, Belarus (3.5%) and Poland (1.8%). In the US it seems to be even lower at .2%.
Why is it so different from country to country? Is it all about the... | 2015/01/02 | [
"https://money.stackexchange.com/questions/41822",
"https://money.stackexchange.com",
"https://money.stackexchange.com/users/20113/"
] | It may seem weird but interest rates are set by a market. Risk is a very large component of the price that a saver will accept to deposit their money in a bank but not the only one.
Essentially you are "lending" deposited cash to the bank that you put it in and they will lend it out at a certain risk to themselves and... | I concur with the answers above - the difference is about the risk. But in this particular case I find the interest level implausible. 11% interest on deposits in USD seems very speculative and unsustainable. You can't guarantee such return on investment unless you engage in drug trade or some other illegal activity. O... |
15,072,265 | How do I write a function that have a input function (is objective to any function), array of input numbers and length of input array?
Function:
```
double accumulator(double (*function)(double, double), double array[], int length)
```
Main:
```
int main(){
double array[10];
for (int i=0; i<10; i++)
a... | 2013/02/25 | [
"https://Stackoverflow.com/questions/15072265",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1852938/"
] | What is wrong with:
```
double multiplicator(double (*function)(double, double), double array[], int length)
{
int temp = 1;
for (int i = 0;i<length;i++)
{
temp = (*function)(temp, array[i]);
}
return temp;
}
```
Either a different function or you need to supply the neutral element for t... | Two thoughts:
1. You should use `double temp` rather than `int temp`.
2. You need to have a different starting value for addition versus multiplication. A sum should start at `temp = 0`, but a product should start at `temp = 1`. Otherwise the product will always be 0.
You could add add another initial value parameter... |
15,072,265 | How do I write a function that have a input function (is objective to any function), array of input numbers and length of input array?
Function:
```
double accumulator(double (*function)(double, double), double array[], int length)
```
Main:
```
int main(){
double array[10];
for (int i=0; i<10; i++)
a... | 2013/02/25 | [
"https://Stackoverflow.com/questions/15072265",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1852938/"
] | It doesn't work for multiplication because multiplying anything by `0` gives, well `0`
you need to use first element as an initial value
```
double accumulator(double (*function)(double, double), double array[], int length)
{
int temp = array[0];
for (int i = 1; i < length;i++) // start from #1
{
... | What is wrong with:
```
double multiplicator(double (*function)(double, double), double array[], int length)
{
int temp = 1;
for (int i = 0;i<length;i++)
{
temp = (*function)(temp, array[i]);
}
return temp;
}
```
Either a different function or you need to supply the neutral element for t... |
15,072,265 | How do I write a function that have a input function (is objective to any function), array of input numbers and length of input array?
Function:
```
double accumulator(double (*function)(double, double), double array[], int length)
```
Main:
```
int main(){
double array[10];
for (int i=0; i<10; i++)
a... | 2013/02/25 | [
"https://Stackoverflow.com/questions/15072265",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1852938/"
] | What is wrong with:
```
double multiplicator(double (*function)(double, double), double array[], int length)
{
int temp = 1;
for (int i = 0;i<length;i++)
{
temp = (*function)(temp, array[i]);
}
return temp;
}
```
Either a different function or you need to supply the neutral element for t... | Your solution is almost there if you set `temp = array[0]` and start your loop at `i = 1` instead of `i = 0`. |
15,072,265 | How do I write a function that have a input function (is objective to any function), array of input numbers and length of input array?
Function:
```
double accumulator(double (*function)(double, double), double array[], int length)
```
Main:
```
int main(){
double array[10];
for (int i=0; i<10; i++)
a... | 2013/02/25 | [
"https://Stackoverflow.com/questions/15072265",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1852938/"
] | It doesn't work for multiplication because multiplying anything by `0` gives, well `0`
you need to use first element as an initial value
```
double accumulator(double (*function)(double, double), double array[], int length)
{
int temp = array[0];
for (int i = 1; i < length;i++) // start from #1
{
... | Two thoughts:
1. You should use `double temp` rather than `int temp`.
2. You need to have a different starting value for addition versus multiplication. A sum should start at `temp = 0`, but a product should start at `temp = 1`. Otherwise the product will always be 0.
You could add add another initial value parameter... |
15,072,265 | How do I write a function that have a input function (is objective to any function), array of input numbers and length of input array?
Function:
```
double accumulator(double (*function)(double, double), double array[], int length)
```
Main:
```
int main(){
double array[10];
for (int i=0; i<10; i++)
a... | 2013/02/25 | [
"https://Stackoverflow.com/questions/15072265",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1852938/"
] | It doesn't work for multiplication because multiplying anything by `0` gives, well `0`
you need to use first element as an initial value
```
double accumulator(double (*function)(double, double), double array[], int length)
{
int temp = array[0];
for (int i = 1; i < length;i++) // start from #1
{
... | Your solution is almost there if you set `temp = array[0]` and start your loop at `i = 1` instead of `i = 0`. |
79,326 | [PyPI](https://pypi.python.org/) is a third-party software repository for Python packages. Everybody can upload packages to it (see [The Python Package Index (PyPI)](https://docs.python.org/2/distutils/packageindex.html)).
* How does PyPI prevent people from uploading malware?
* When I am searching for software, how c... | 2015/01/16 | [
"https://security.stackexchange.com/questions/79326",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/3286/"
] | I actually wrote a [blog post](http://www.ayrx.me/look-before-you-pip/) on this topic recently.
To answer your points:
>
> How does PyPI prevent people from uploading malware?
>
>
>
It doesn't. *Any* Python code can be uploaded. Arbitrary code execution is possible during package installation. Audit your depende... | As far as I'm aware, in general there are very limited assurances around the code available from online code repositories (e.g. rubygems, npm, nuget, PyPI etc). In a lot of cases they don't support or enforce things like signed code or other integrity based security measures and authentication to the sites to deploy is... |
79,326 | [PyPI](https://pypi.python.org/) is a third-party software repository for Python packages. Everybody can upload packages to it (see [The Python Package Index (PyPI)](https://docs.python.org/2/distutils/packageindex.html)).
* How does PyPI prevent people from uploading malware?
* When I am searching for software, how c... | 2015/01/16 | [
"https://security.stackexchange.com/questions/79326",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/3286/"
] | I actually wrote a [blog post](http://www.ayrx.me/look-before-you-pip/) on this topic recently.
To answer your points:
>
> How does PyPI prevent people from uploading malware?
>
>
>
It doesn't. *Any* Python code can be uploaded. Arbitrary code execution is possible during package installation. Audit your depende... | As of 2020, `pip` does not provide cryptographic integrity or authentication on any of the packages it downloads from PyPI.
In 2013, [PEP 458](https://www.python.org/dev/peps/pep-0458) was presented as a solution to fix this.
In 2019, the Python Software Foundation [announced that Facebook donated](https://pyfound.bl... |
79,326 | [PyPI](https://pypi.python.org/) is a third-party software repository for Python packages. Everybody can upload packages to it (see [The Python Package Index (PyPI)](https://docs.python.org/2/distutils/packageindex.html)).
* How does PyPI prevent people from uploading malware?
* When I am searching for software, how c... | 2015/01/16 | [
"https://security.stackexchange.com/questions/79326",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/3286/"
] | There are two threat models here:
1. Malicious developer uploading malicious packages
2. Malicious attacker uploading malicious packages that belongs to legitimate developers
PyPI does not make any attempt to try to resolve #1. Auditing code before installs and only installing packages from reputable developers are t... | As far as I'm aware, in general there are very limited assurances around the code available from online code repositories (e.g. rubygems, npm, nuget, PyPI etc). In a lot of cases they don't support or enforce things like signed code or other integrity based security measures and authentication to the sites to deploy is... |
79,326 | [PyPI](https://pypi.python.org/) is a third-party software repository for Python packages. Everybody can upload packages to it (see [The Python Package Index (PyPI)](https://docs.python.org/2/distutils/packageindex.html)).
* How does PyPI prevent people from uploading malware?
* When I am searching for software, how c... | 2015/01/16 | [
"https://security.stackexchange.com/questions/79326",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/3286/"
] | As far as I'm aware, in general there are very limited assurances around the code available from online code repositories (e.g. rubygems, npm, nuget, PyPI etc). In a lot of cases they don't support or enforce things like signed code or other integrity based security measures and authentication to the sites to deploy is... | As of 2020, `pip` does not provide cryptographic integrity or authentication on any of the packages it downloads from PyPI.
In 2013, [PEP 458](https://www.python.org/dev/peps/pep-0458) was presented as a solution to fix this.
In 2019, the Python Software Foundation [announced that Facebook donated](https://pyfound.bl... |
79,326 | [PyPI](https://pypi.python.org/) is a third-party software repository for Python packages. Everybody can upload packages to it (see [The Python Package Index (PyPI)](https://docs.python.org/2/distutils/packageindex.html)).
* How does PyPI prevent people from uploading malware?
* When I am searching for software, how c... | 2015/01/16 | [
"https://security.stackexchange.com/questions/79326",
"https://security.stackexchange.com",
"https://security.stackexchange.com/users/3286/"
] | There are two threat models here:
1. Malicious developer uploading malicious packages
2. Malicious attacker uploading malicious packages that belongs to legitimate developers
PyPI does not make any attempt to try to resolve #1. Auditing code before installs and only installing packages from reputable developers are t... | As of 2020, `pip` does not provide cryptographic integrity or authentication on any of the packages it downloads from PyPI.
In 2013, [PEP 458](https://www.python.org/dev/peps/pep-0458) was presented as a solution to fix this.
In 2019, the Python Software Foundation [announced that Facebook donated](https://pyfound.bl... |
41,971,499 | I'm a bit new to Angularjs. I'm confused about multiple controllers. I know Angular app can have multiple controllers. But I'm confused when to use multiple controllers. What's the advantage of having multiple controllers? Can anyone help me to clarify this? Thanks | 2017/02/01 | [
"https://Stackoverflow.com/questions/41971499",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] | In order to modularize your application based on the feature wise, you can have multiple controllers.
For example if you have a login feature, you can have a separate controller which does the login part(Fetching data,checking the authentication etc)
```
var app = angular.module('app', []);
app.controller('LoginCont... | For different functions we need different controllers. For example if you need a ui modal to display something then for that modal you need different controller which will handle only modal's functionality. If you try to code everything in single controller then it will be confusing for you when in future you want to e... |
38,206,383 | I am trying to use JavaScript (inside PHP) to recognize keyDown events - specifically the arrow keys. I have looked through various threads on here, as well as other sources but have not been able to find a solution. My code looks like:
```
echo '<script>
alert ("Hi");
$(document).keydown = (function(e) {
if (e... | 2016/07/05 | [
"https://Stackoverflow.com/questions/38206383",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6500824/"
] | One possibility is to use an *unboxed mutable* vector and *freeze* it once done with construction:
```
import Control.Monad.ST (runST)
import Control.Monad (forM_, ap)
import qualified Data.Vector.Unboxed as U
import qualified Data.Vector.Unboxed.Mutable as M
fib :: Int -> U.Vector Int
fib s = runST $ M.new s >>= ap ... | The only way I can think of to do this is to generate a lazy recursive list, and then convert that to an unboxed vector.
The standard baffling incantation
```
fibs = 1 : 1 : zipWith (+) fibs (tail fibs)
```
will give you an infinite list of Fibonacci numbers. You can then build an unboxed list from that, which will... |
38,206,383 | I am trying to use JavaScript (inside PHP) to recognize keyDown events - specifically the arrow keys. I have looked through various threads on here, as well as other sources but have not been able to find a solution. My code looks like:
```
echo '<script>
alert ("Hi");
$(document).keydown = (function(e) {
if (e... | 2016/07/05 | [
"https://Stackoverflow.com/questions/38206383",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6500824/"
] | `constructN` does what you want, even in the unboxed case. Below, `v` is the vector prefix built so far, and `f v` returns the next element.
Optimal O(N) complexity.
```
import qualified Data.Vector.Unboxed as V
fib :: V.Vector Int
fib = V.constructN 10 f
where
f v = case V.length v of
0 -> 0
... | The only way I can think of to do this is to generate a lazy recursive list, and then convert that to an unboxed vector.
The standard baffling incantation
```
fibs = 1 : 1 : zipWith (+) fibs (tail fibs)
```
will give you an infinite list of Fibonacci numbers. You can then build an unboxed list from that, which will... |
38,206,383 | I am trying to use JavaScript (inside PHP) to recognize keyDown events - specifically the arrow keys. I have looked through various threads on here, as well as other sources but have not been able to find a solution. My code looks like:
```
echo '<script>
alert ("Hi");
$(document).keydown = (function(e) {
if (e... | 2016/07/05 | [
"https://Stackoverflow.com/questions/38206383",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6500824/"
] | One possibility is to use an *unboxed mutable* vector and *freeze* it once done with construction:
```
import Control.Monad.ST (runST)
import Control.Monad (forM_, ap)
import qualified Data.Vector.Unboxed as U
import qualified Data.Vector.Unboxed.Mutable as M
fib :: Int -> U.Vector Int
fib s = runST $ M.new s >>= ap ... | `constructN` does what you want, even in the unboxed case. Below, `v` is the vector prefix built so far, and `f v` returns the next element.
Optimal O(N) complexity.
```
import qualified Data.Vector.Unboxed as V
fib :: V.Vector Int
fib = V.constructN 10 f
where
f v = case V.length v of
0 -> 0
... |
19,271,455 | I am working on a comet based session logout system,Actually i want to check user session is active or not without sending ajax request every time to the server.so when user login first time, a request goes to the server(Servlet) and hold until sessionout(a thread check),how can a thread handle session for every user a... | 2013/10/09 | [
"https://Stackoverflow.com/questions/19271455",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1919643/"
] | I think a thread checks whole session guys every 1 min(or less) and just remove the expired sessions, and also this is hardly possible that each session has its own life thread that it makes the server heavy.
if you are trying to doing same, you need a thread (daemon mode will be okay) that after a 1min sleep checks al... | So my suggestion is keep every session in a global reference, like a list in a singleton class, then the class also run a thread that refresh each session each 1 min, something like this, BUT I DON NOT KNOW that the server refreshes the session expire time with HttpServeltRequest reference or with HttpSession itself, a... |
33,357,038 | When using getters and setters in object literals, I cannot see an easy way to access the outer "this" scope in Typescript. Consider the following:
```
class Report {
stuff: any[];
options = {
length: 10,
get maxLength() { return REPORT.stuff.length }
}
}
```
Where `REPORT` wants to be a... | 2015/10/26 | [
"https://Stackoverflow.com/questions/33357038",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/966104/"
] | >
> I realize that I can solve this by setting options within the constructor and using a var REPORT = this or similar, but seems inelegant
>
>
>
Instead of setting up option in the constructor you can take advantage of the fact that `options` \*is being defined in the constructor. Thus, store `this` into `options... | You can take advantage of the `this` binding of lambdas.
```
class Report {
stuff: any[];
options = {
length: 10,
maxLength: () => this.stuff.length
}
}
```
compiles to
```
var Report = (function () {
function Report() {
var _this = this;
this.options = {
... |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | Try putting a 6v2 zener (400mW) diode in series with the indicator LED. The LED takes about 1.5V so nothing under 7.7V should be able to turn it on. The LED current should be small enough to use a low power zener diode. Make sure you get the diode the right way around.
. |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | I'll expand on one of cinelli's comments - why not fix the cause rather than the symptom? If you've got 6v on the high-beam feed when the switch is set to dip, this suggests to me there is a problem with the switch - and I'd be worried that it might be causing other hidden problems.
For example, if the lamps aren't re... | If this is a simple logic chip that is detecting it, then you won't need a lot of current to trigger. In that case, just put something like two 1K resistors in series to ground and divide the voltage in half (the old output will now be in between the two resistors). |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | If this is a simple logic chip that is detecting it, then you won't need a lot of current to trigger. In that case, just put something like two 1K resistors in series to ground and divide the voltage in half (the old output will now be in between the two resistors). | I had to figure out where the 6V came from so I drew 2 lamps side by side and gave each a ground connection. I provided them both with 12V to establish 2 lamps in paralell. I then misconnected one of the grounds to 12v and realized 6V on the supply side of the lamps. Poor boy got his wires crossed. |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | Try putting a 6v2 zener (400mW) diode in series with the indicator LED. The LED takes about 1.5V so nothing under 7.7V should be able to turn it on. The LED current should be small enough to use a low power zener diode. Make sure you get the diode the right way around.
, If one of the connectors is corrodded etc. A little more details on the year make and model of th... |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | I'll expand on one of cinelli's comments - why not fix the cause rather than the symptom? If you've got 6v on the high-beam feed when the switch is set to dip, this suggests to me there is a problem with the switch - and I'd be worried that it might be causing other hidden problems.
For example, if the lamps aren't re... | Try putting a 6v2 zener (400mW) diode in series with the indicator LED. The LED takes about 1.5V so nothing under 7.7V should be able to turn it on. The LED current should be small enough to use a low power zener diode. Make sure you get the diode the right way around.
 diode in series with the indicator LED. The LED takes about 1.5V so nothing under 7.7V should be able to turn it on. The LED current should be small enough to use a low power zener diode. Make sure you get the diode the right way around.
, If one of the connectors is corrodded etc. A little more details on the year make and model of th... |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | The indicator lamp on some vehicles is also illuminated if the resistance in the wiring is not equal to a certain amount. This is usually cause by using an incorrect bulb (even though the bulb will still plug in and work), If one of the connectors is corrodded etc. A little more details on the year make and model of th... | I had to figure out where the 6V came from so I drew 2 lamps side by side and gave each a ground connection. I provided them both with 12V to establish 2 lamps in paralell. I then misconnected one of the grounds to 12v and realized 6V on the supply side of the lamps. Poor boy got his wires crossed. |
6,618 | I have a situation where I'm doing wiring for the dashboard of a vehicle. For whatever reason, the turn signal/headlight switch on this vehicle outputs a 6 volt signal on the high beam wire when the low beam is on and a 12 volt signal when the high beam is on. The headlights work as they're supposed to, but the high be... | 2013/07/11 | [
"https://mechanics.stackexchange.com/questions/6618",
"https://mechanics.stackexchange.com",
"https://mechanics.stackexchange.com/users/-1/"
] | I'll expand on one of cinelli's comments - why not fix the cause rather than the symptom? If you've got 6v on the high-beam feed when the switch is set to dip, this suggests to me there is a problem with the switch - and I'd be worried that it might be causing other hidden problems.
For example, if the lamps aren't re... | I had to figure out where the 6V came from so I drew 2 lamps side by side and gave each a ground connection. I provided them both with 12V to establish 2 lamps in paralell. I then misconnected one of the grounds to 12v and realized 6V on the supply side of the lamps. Poor boy got his wires crossed. |
3,674,246 | The common counterexample that the infinite union of compact sets need not be compact is to take $A\_n = [-n, n]$, whose infinite union $\mathbb{R}$ is not compact. However, I was wondering if this is also true for infinite unions of decreasingly nested compact subsets (i.e. $C\_n \supset C\_{n+1} \supset C\_{n+2} \sup... | 2020/05/14 | [
"https://math.stackexchange.com/questions/3674246",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/494405/"
] | Here is a big hint. Let $$f(x) = (5 + \sqrt{26})^x + (5 - \sqrt{26})^x.$$ Then $f(0) = 2$, $f(1) = 10$, and in general for $x = 2, 3, \ldots$, we have the recursion relation
$$f(x)f(1) = f(x+1) + (5 + \sqrt{26})(5 - \sqrt{26})f(x-1) = f(x+1) - f(x-1),$$ or $$f(x+1) = 10f(x) + f(x-1).$$ Consequently, $f(x)$ is an intege... | So take $a=5+\sqrt {26}, b=5-\sqrt {26}$ and note that $0\lt -b \lt 1$ (in fact $b \approx -0.1$)
Now note that $a+b=10$ and $ab=-1$ [whence $a=-\frac 1b$ and you can verify the estimate for $b$, because $a\gt 10$]
So $a$ and $b$ are roots of the quadratic $x^2-10x-1=0$ or $x^2=10x+1$ or $x^{n+2}=10x^{n+1}+x^n$
Let ... |
3,674,246 | The common counterexample that the infinite union of compact sets need not be compact is to take $A\_n = [-n, n]$, whose infinite union $\mathbb{R}$ is not compact. However, I was wondering if this is also true for infinite unions of decreasingly nested compact subsets (i.e. $C\_n \supset C\_{n+1} \supset C\_{n+2} \sup... | 2020/05/14 | [
"https://math.stackexchange.com/questions/3674246",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/494405/"
] | Here is a big hint. Let $$f(x) = (5 + \sqrt{26})^x + (5 - \sqrt{26})^x.$$ Then $f(0) = 2$, $f(1) = 10$, and in general for $x = 2, 3, \ldots$, we have the recursion relation
$$f(x)f(1) = f(x+1) + (5 + \sqrt{26})(5 - \sqrt{26})f(x-1) = f(x+1) - f(x-1),$$ or $$f(x+1) = 10f(x) + f(x-1).$$ Consequently, $f(x)$ is an intege... | This phenomenon reminds of the Fibonacci sequence, that follows the recurrence
$$F\_{n}=F\_{n-1}+F\_{n-2}$$ with initial values such that $F\_n$ is always an integer.
$$0,1,2,3,5,8,13,21,34,\cdots$$
At the same time, it can be shown that
$$F\_n=\frac{\phi^n-\psi^{-n}}{\sqrt 5}$$ where $\phi$ and $\psi$ are the root... |
3,674,246 | The common counterexample that the infinite union of compact sets need not be compact is to take $A\_n = [-n, n]$, whose infinite union $\mathbb{R}$ is not compact. However, I was wondering if this is also true for infinite unions of decreasingly nested compact subsets (i.e. $C\_n \supset C\_{n+1} \supset C\_{n+2} \sup... | 2020/05/14 | [
"https://math.stackexchange.com/questions/3674246",
"https://math.stackexchange.com",
"https://math.stackexchange.com/users/494405/"
] | So take $a=5+\sqrt {26}, b=5-\sqrt {26}$ and note that $0\lt -b \lt 1$ (in fact $b \approx -0.1$)
Now note that $a+b=10$ and $ab=-1$ [whence $a=-\frac 1b$ and you can verify the estimate for $b$, because $a\gt 10$]
So $a$ and $b$ are roots of the quadratic $x^2-10x-1=0$ or $x^2=10x+1$ or $x^{n+2}=10x^{n+1}+x^n$
Let ... | This phenomenon reminds of the Fibonacci sequence, that follows the recurrence
$$F\_{n}=F\_{n-1}+F\_{n-2}$$ with initial values such that $F\_n$ is always an integer.
$$0,1,2,3,5,8,13,21,34,\cdots$$
At the same time, it can be shown that
$$F\_n=\frac{\phi^n-\psi^{-n}}{\sqrt 5}$$ where $\phi$ and $\psi$ are the root... |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | A way around this issue is to stop VS Code from redundantly printing to the `TERMINAL` during debugging in the first place. Since it prints to the `DEBUG CONSOLE` as well, you can use that instead.
Change `console` to ~~`"none"`~~ `"internalConsole"` in each configuration in your project's `launch.json` file:
```
"c... | Adding `"args": ["&&", "exit"],` to `launch.json` remedies this for Git Bash. Certainly a hack, but I no longer have to manually close many debug terminals. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | A way around this issue is to stop VS Code from redundantly printing to the `TERMINAL` during debugging in the first place. Since it prints to the `DEBUG CONSOLE` as well, you can use that instead.
Change `console` to ~~`"none"`~~ `"internalConsole"` in each configuration in your project's `launch.json` file:
```
"c... | Actually you can **delete** all the instances of the **terminal** just by clicking on the **trash can icon** . If it does not work for the first time, **restart** the **VS Code** and try again. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | A way around this issue is to stop VS Code from redundantly printing to the `TERMINAL` during debugging in the first place. Since it prints to the `DEBUG CONSOLE` as well, you can use that instead.
Change `console` to ~~`"none"`~~ `"internalConsole"` in each configuration in your project's `launch.json` file:
```
"c... | Hopefully fixed in the Insiders Build and should be in v1.54. See [Debug opens a new integrated terminal for each Python session](https://github.com/microsoft/vscode/issues/112055). Test it in the Insiders Build if you can and report at the issue if it fixed/did not fix. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | A way around this issue is to stop VS Code from redundantly printing to the `TERMINAL` during debugging in the first place. Since it prints to the `DEBUG CONSOLE` as well, you can use that instead.
Change `console` to ~~`"none"`~~ `"internalConsole"` in each configuration in your project's `launch.json` file:
```
"c... | This may have been resolved in recent debug updates to core VS Code within the last year (as of 8/2022), but I was still seeing this intermittently.
I don't know if this will help the original poster, but I discovered that for me the issue persisted due to using Git Bash as the default terminal in Windows. Switching t... |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | Adding `"args": ["&&", "exit"],` to `launch.json` remedies this for Git Bash. Certainly a hack, but I no longer have to manually close many debug terminals. | Actually you can **delete** all the instances of the **terminal** just by clicking on the **trash can icon** . If it does not work for the first time, **restart** the **VS Code** and try again. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | Adding `"args": ["&&", "exit"],` to `launch.json` remedies this for Git Bash. Certainly a hack, but I no longer have to manually close many debug terminals. | Hopefully fixed in the Insiders Build and should be in v1.54. See [Debug opens a new integrated terminal for each Python session](https://github.com/microsoft/vscode/issues/112055). Test it in the Insiders Build if you can and report at the issue if it fixed/did not fix. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | Adding `"args": ["&&", "exit"],` to `launch.json` remedies this for Git Bash. Certainly a hack, but I no longer have to manually close many debug terminals. | This may have been resolved in recent debug updates to core VS Code within the last year (as of 8/2022), but I was still seeing this intermittently.
I don't know if this will help the original poster, but I discovered that for me the issue persisted due to using Git Bash as the default terminal in Windows. Switching t... |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | This may have been resolved in recent debug updates to core VS Code within the last year (as of 8/2022), but I was still seeing this intermittently.
I don't know if this will help the original poster, but I discovered that for me the issue persisted due to using Git Bash as the default terminal in Windows. Switching t... | Actually you can **delete** all the instances of the **terminal** just by clicking on the **trash can icon** . If it does not work for the first time, **restart** the **VS Code** and try again. |
53,974,197 | Every time I build or run a program in VSCode a new python debug console is loaded. Before I know it I have 20+ and need to start deleting them. After 32 open consoles I get the error "The terminal process terminated with exit code: 256". I changed the terminal from the default console to git bash recently. How can I s... | 2018/12/29 | [
"https://Stackoverflow.com/questions/53974197",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7371561/"
] | This may have been resolved in recent debug updates to core VS Code within the last year (as of 8/2022), but I was still seeing this intermittently.
I don't know if this will help the original poster, but I discovered that for me the issue persisted due to using Git Bash as the default terminal in Windows. Switching t... | Hopefully fixed in the Insiders Build and should be in v1.54. See [Debug opens a new integrated terminal for each Python session](https://github.com/microsoft/vscode/issues/112055). Test it in the Insiders Build if you can and report at the issue if it fixed/did not fix. |
456,096 | A while back I bought two DS18B20 for half price, and today I bought another one for double the price. The part number on the cheaper one is printed while on the expensive one it's laser etched:
[](https://i.stack.imgur.com/DRa8p.jpg)
*On the left is the expensive one.*
Even t... | 2019/09/04 | [
"https://electronics.stackexchange.com/questions/456096",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/185519/"
] | **There isn't any good way to know.** As Elliot Alderson rightly points out, both could be legitimate, or both could be fake.
* If the packaging and marking are different between the two parts, that could simply be because the manufacturer changed their packaging process. You'd have to check product change notices to ... | As of June 2020, you can know with good accuracy. The accepted answer is not completely correct anymore.
All the information is provided in <https://github.com/cpetrich/counterfeit_DS18B20> which also links to Arduino sketches which can tell you, based on the expected data returned by the chip, whether your sensor is ... |
456,096 | A while back I bought two DS18B20 for half price, and today I bought another one for double the price. The part number on the cheaper one is printed while on the expensive one it's laser etched:
[](https://i.stack.imgur.com/DRa8p.jpg)
*On the left is the expensive one.*
Even t... | 2019/09/04 | [
"https://electronics.stackexchange.com/questions/456096",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/185519/"
] | **There isn't any good way to know.** As Elliot Alderson rightly points out, both could be legitimate, or both could be fake.
* If the packaging and marking are different between the two parts, that could simply be because the manufacturer changed their packaging process. You'd have to check product change notices to ... | Thanks to Chris for his testing and counterfeit detection sketches!
Maybe the attached graph of the readings from four sensors I purchased from a Chinese supplier on eBay plus one genuine Maxim DS18B20 (bought from a reputable distributor) will answer the question.
All five sensors are at the same temperature. It's p... |
456,096 | A while back I bought two DS18B20 for half price, and today I bought another one for double the price. The part number on the cheaper one is printed while on the expensive one it's laser etched:
[](https://i.stack.imgur.com/DRa8p.jpg)
*On the left is the expensive one.*
Even t... | 2019/09/04 | [
"https://electronics.stackexchange.com/questions/456096",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/185519/"
] | After purchasing many DS18B20 sensors and probes on ebay I can assure you that price is a useless indicator for quality.
Let me address the question in the title of this thread: **Which one of these DS18B20 temperature sensors is fake?**
Fortunately, you can find out for yourself: you cannot proof that a part is auth... | As of June 2020, you can know with good accuracy. The accepted answer is not completely correct anymore.
All the information is provided in <https://github.com/cpetrich/counterfeit_DS18B20> which also links to Arduino sketches which can tell you, based on the expected data returned by the chip, whether your sensor is ... |
456,096 | A while back I bought two DS18B20 for half price, and today I bought another one for double the price. The part number on the cheaper one is printed while on the expensive one it's laser etched:
[](https://i.stack.imgur.com/DRa8p.jpg)
*On the left is the expensive one.*
Even t... | 2019/09/04 | [
"https://electronics.stackexchange.com/questions/456096",
"https://electronics.stackexchange.com",
"https://electronics.stackexchange.com/users/185519/"
] | After purchasing many DS18B20 sensors and probes on ebay I can assure you that price is a useless indicator for quality.
Let me address the question in the title of this thread: **Which one of these DS18B20 temperature sensors is fake?**
Fortunately, you can find out for yourself: you cannot proof that a part is auth... | Thanks to Chris for his testing and counterfeit detection sketches!
Maybe the attached graph of the readings from four sensors I purchased from a Chinese supplier on eBay plus one genuine Maxim DS18B20 (bought from a reputable distributor) will answer the question.
All five sensors are at the same temperature. It's p... |
127,624 | I'm quite new to trying to write my own macros and I've been able to piece this one together, but it takes quite some time to run. Here is the macro for one value (I have to create workbooks for ~20 different values). Are there any ways I can improve its speed?
Also, I am assuming I can just replicate my `For`/`Next` ... | 2016/05/04 | [
"https://codereview.stackexchange.com/questions/127624",
"https://codereview.stackexchange.com",
"https://codereview.stackexchange.com/users/105847/"
] | (I am referring to the Swift code only.)
You can declare a property as
```
public private(set) var name: String?
```
to make it public read-only, but internally read-write. That makes
the additional accessor `getName()` obsolete.
If the property is only assigned in the init method and never
changed later, you can ... | In Objective-C, you could define a class property like this,
```
@interface User : NSObject
@property (class, nonatomic, strong) User *currentUser;
@end
```
Maybe that's what you want.
For the static variable, yes, it could be accessed in both class and instance level in its own namespace. |
5,155,723 | I have a question regarding inheritance, so I will describe the scenario below:
I am reading a text file containing logs. (One log per line)
Each log-line will have the following format:
"Date Type Description"
However, depending on the "Type" of log, I will have to parse the "Description" differently and pull out di... | 2011/03/01 | [
"https://Stackoverflow.com/questions/5155723",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/479317/"
] | As per my comment, why not just do something a little like this:
```
public enum LogEntryType
{
Error = -1,
Information = 0,
}
public class LogEntry
{
public string Raw;
public DateTime Date;
public LogEntryType Type;
public string Description;
... | Try to use [Factory pattern](http://en.wikipedia.org/wiki/Factory_method_pattern)
```
static class LogFactory
{
public static Log Create(String line)
{
if(GetType(line) == "Information")
return CreateInformationLog(line);
return CreateLog(line);
}
private static Log CreateLo... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.