query_id stringlengths 4 64 | query_authorID stringlengths 6 40 | query_text stringlengths 66 72.1k | candidate_id stringlengths 5 64 | candidate_authorID stringlengths 6 40 | candidate_text stringlengths 9 101k |
|---|---|---|---|---|---|
f70b47e7f50793a223708465e8ad78b835b27d01aadcb69280d97d0debf31605 | ['c6048c27d1294d7abd394d85a73d0b1c'] | I have made a Music Genre Classification Convolutional NN Model in Tensorflow and I face a issue:
I have 999 music Spectrogram images in my X and also have appropriate labels(y). The images are of size (128,1293).
When I check the shape of X it shows me (999,),which signifies number of images ; however I wish to expand... | 21b5f2c85c3025c0d7c42686f92b22e3da93ab109dd61247f802e92bd977901f | ['c6048c27d1294d7abd394d85a73d0b1c'] | I am plotting a scatter plot of price of houses w.r.t latitude and longitude.
I want to reverse the palette so that the red color depicts the most expensive house.
plt.figure(figsize=(12,8))
sns.scatterplot(x='long' ,y='lat' ,data=non_top_1_perc ,hue='price' ,edgecolor=None ,
alpha=0.2,palette='RdYlGn' )
Here's the ... |
518b3b47917ab1f9d45fec046452b934ccd9c9d26adc603390008b8f8f569aab | ['c60edd9082924bc08be54bfb9e301879'] | I have NodeJS on / path.
On /another.ejs path, I have a little website and I wanna get data from /value path.
I cannot do this call with pure JS and AJAX, because of CORS.
Can I do something like when I click on button, it calls function in NodeJS and return data?
| ab03956affbff7c46c08af8d681ad21f7a00b1debb67443e75c97374febe795e | ['c60edd9082924bc08be54bfb9e301879'] | // index.js //
module.exports = (req, res) => {
res.send("Hello World!");
};
This function is called when I require the file.
let index = require("./index.js");
app.get("/", index);
Can I add some another functions to module.exports?
Like this:
// index.js //
module.exports = (req, res) => {
res.send("Hello W... |
ac93ea7e6e5bef5568ce9634f7c3a22d1ad3febba6c0923ccbab7bab00415e04 | ['c61dc172e76a498381aeb787b72716d4'] | if (!isset($_COOKIE['language'])) {
$GLOBALS['langswitch'] = "EN";
} elseif ($_COOKIE['language'] === "tr") {
$GLOBALS['langswitch'] = "EN";
} elseif ($_COOKIE['language'] === "en") {
$GLOBALS['langswitch'] = "TR";
}
function languageSwitch (){
if ($GLOBALS['langswitch'] == "EN"){
echo "en"... | 90e9074a82a595fba5881f9305b1cb0b7886941a9433a725b66b40877018b5b2 | ['c61dc172e76a498381aeb787b72716d4'] | I have a function to change my website's language and inside this function there is an if statement which chooses between two languages (Turkish and English) but before i run the function the if statement works and conditions apply i want to wait until after the function is executed.
setcookie("language", "tr", time()+... |
2e06a816e6bbf6db1b981ddb380f1ddee57d6eb5972fbef3a60b9ffdef413c61 | ['c6210c9f6a9244b7b7e842301bcfc90a'] | I have a Gridview within an UpdatePanel that shows some data from my Database. When you click on an edit button, it opens up a detailsView within a ModalPopupextender. When you enter in data in the textBoxes in this detailView and click "update", the Database is updated but the popup does not hide. Then, when I clos... | 16f738c9fa3a0278d038ed0b508a15da7072a99214eb1e36821c43aa21c07f74 | ['c6210c9f6a9244b7b7e842301bcfc90a'] | Actually I can do that, thank you <PERSON>, using the one word userID/user name however I wanted to login with my first ID as well.
Is there a way to change/reset my userID, which has two words in it, without loosing functionality of other programs/software as I may not be able to login to a database managed software ... |
5adcbf0739861690d05b38cf764505f6ec46214d834ab9b8edf19c99a47c82ec | ['c6243e8e654a4eaca148c495144baa06'] | Покажите реализацию класса Obstacle - вожможно, там используется Image вместо BufferedImage или выполняются какие-то расчёты в методе getImage. Ещё пара советов: 1) не надо хранить координаты в отдельном массиве, их можно поместить в экземпляры класса Obstacle 2) в методе run() не надо постоянно вызывать System.getCur... | d2e0b124b3ab680261843b51750a54ab8d771c6ce68e044b4047b20b2faf95f3 | ['c6243e8e654a4eaca148c495144baa06'] | I'm trying to solve a classification problem using a random forest in R. The training data is a particle's charge at 30 different time instances. However, I need to convert this 30 dimensional data into a single value. I've tried using the sum of the charge across the 30 time bins and I've tried using the variable impo... |
c0391bcb2c9e00c3d8d8ae337362f66a278b366c6fec712a96b23ca53687519e | ['c66aa33fdac34398a561f4bff8f503ee'] | The closest thing I found is this command ffmpeg -i in.mp4 -filter:v "crop=in_w:in_h-40" -c:a copy out.mp4
, which crops the video 20px from the top and 20px from the bottom.
What's the command to only crop from the top? I couldn't figure it out.
| 8abb25efdc44c2dfaaab43c2fb745364fb304f2a01f8973ceebf4d3a3bc116e1 | ['c66aa33fdac34398a561f4bff8f503ee'] | I have a code snippet like this
#include <cstring>
#define DISABLE_DEFAULT_NEW \
void* operator new(size_t aSize, void* aPtr); \
void operator delete(void* aPtr);
class A
{
public:
DISABLE_DEFAULT_NEW
A() {}
};
int
main()
{
... |
e2e6762a46b0286b04847eba94dee02e1d77f830e12e7ffbed46f267c0f54d95 | ['c66decb764844d638625ed5405d593c8'] | My VB has failed. It's 99% of the way there. Just setting up the While Not end of file loop. It's flummoxed me sorry. If you knew the number of Hex entries you could do a do or while loop setting the counter to that number and just decrement the counter. | 221cee6bf9bc4215a4682335ae3b92c7071f97632e42eaa0e08d85071b2cd333 | ['c66decb764844d638625ed5405d593c8'] | I am really trying hard to force myself into believing this, but I just can't fathom. This makes me wonder why Christianity is even a religion. I like and follow the teachings of <PERSON>, but it's hard to believe that <PERSON> was a God (or the God, sorry). |
87d5cd1b7739be07010e6505523b6052f6e958ebc37de5c8cd948bb89666871e | ['c675ee1fd5654c4a871a333706278c76'] | if both white noise sound is traveling in same direction And if their frequency is in phase matched up, then only they get added. But, one thing i am not sure about is after adding up will it remain as white noise or it will become some other type of sound having different frequency.
| 650aae0866859077b478ad48a2623550ec5b8d2e949b8fb0c9f94c360f56a4dd | ['c675ee1fd5654c4a871a333706278c76'] | En esta dirección tienes herramientas conversoras:
using System;
public static void Main(string[] args)
{
/* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */
Scanner ob = new Scanner(System.in);
Solution solution = null;
int testcases = ob.Nex... |
1028f44932f4f0b452643f2aebcae2b9f8c7bbd6dab186186f98b1f00cf30e37 | ['c67e06256ea647fcb8c1a008d4bfed4e'] | Is there a name for the infinite (repeating, unending) sentence or paragraph? Here is an example of what I mean:
<PERSON> is a chef, painter, author and vocalist from San Francisco who enjoys vinyl records, black and white movies and referring to himself in third-person, as in “<PERSON> is a chef, painter, author and v... | f5527950460a4053ca3aeead692e642630408be0cc869a18c92fe818f0912b02 | ['c67e06256ea647fcb8c1a008d4bfed4e'] | @VladD, Действительно ошибку выдает:
BindingExpression path error: 'IsHidden' property not found on 'object' ''MainViewModel' (HashCode=21855962)'. BindingExpression:Path=IsHidden; DataItem='MainViewModel' (HashCode=21855962); target element is 'ListView' (Name=''); target property is 'NoTarget' (type 'Object')
Св... |
402d91d6eb03fa65cdac5b077d727e17ae3629ccb2011d60ad03ca38acf01769 | ['c69083496b9e4f3fa33a85579f66cacc'] | I'm trying to pass a global defined array as an argument to a function.
I thougt this function would treat the argument as a local variable.
But it doesn't... Changing the (in my opinion) local variable also changes the values of the global array. What am I doing wrong?
clickX = [];
for(var i=0; i<10; i++) {
clickX... | 50750fc8bc7b614b18685247c9c849216b5dc6796ddf2c223c0bdabdb270673a | ['c69083496b9e4f3fa33a85579f66cacc'] | I'm planning to develop a HTML5-App which should be capable of playing 360°-Videos using the Device Orientation of the smartphone. By moving the smartphone the player should pan and tilt the video.
A first idea was to simply embed a YouTube-360-Video. But the YouTube-Browser-Player doesn't seem to make use of the devic... |
dfb66a4ec313372da40adc76b50674de4f5c33e32c690e942741f713f224f476 | ['c69af8750a154e6c9084d27ae7fbc766'] | I have 2 separate JS objects which need to be merged into the same property.
The objects currently look like this:
Object 1:
[0:{"acircuit":"ABCDEFGH","astatus":"Test"}, 1:{"acircuit":"IJKLMNOP","astatus":"Test2"}]
Object 2:
[0:{"bcircuit":"ABCDEFGH","bstatus":"Test3"}, 1:{"bcircuit":"IJKLMNOP","bstatus":"Test4"}]
I ... | ddc0894e3fc901ed9f149188a4f8b8c0302d91184538eb13a3c0f8ae234f3670 | ['c69af8750a154e6c9084d27ae7fbc766'] | I'm new to the React framework and recently wrote the below code but have been asked to understand what is wrong with it and how I could improve/fix this component.
Please could someone advise a better way of structuring this component and why this approach? Thanks!
class App extends React.Component {
constructor(p... |
2cf94c99c20efa15485e58ec97f4a80aa0bad589bc325cfb5dfe3363bacee0bf | ['c6a0d05955fe4a87bd353d90033181ba'] | I have the following situation:
I have a scene lighted by a "sun" lamp that gives me good sharp shadows. But I also want to have a large plane with an emissive material placed above the scene to regulate the "general" brightness. My problem is that while this plane does emit light the way I want it to, it also blocks t... | 20ed57630ab408199f6b2ee6b209b8f4417c9b9ddf27acb7d3b9de4f6b0129f8 | ['c6a0d05955fe4a87bd353d90033181ba'] | No classism, just trying to figure things out in a limited time frame. There are reasons for why I'm trying to push the boundaries of standard practice and NEC, but, for better of worse, I'd rather leave them out of the discussion. Thanks for pointing to better places for these kinds of questions. |
f0f6a40b91841cc4bc3b8400ef9ce2f6a20bcbf537f54494543cf575109452e4 | ['c6a339a719f94ffe9f2bbba96ba47d0f'] | Not sure if phishing.How did link on letter affect my Yahoo mail layout? I myself though have had good experience with new unknown journal, now has earned impact factor and I am pleased with two journals I published in though they were on suspect list. But there is opportunity for phishing whenever using link in email... | 91f59a1661babb386637a9b6086bb9336ef91ac10aad4cbd90673457cb15b8e6 | ['c6a339a719f94ffe9f2bbba96ba47d0f'] | I found Wikipedia to have listed Hellinger distance between pairs of 2-parameter Weibull distributions sharing the same shape parameter
http://en.wikipedia.org/wiki/Hellinger_distance
However, I wasn't able to find any information on Helinger distance between pairs of 3-parameter Weibull distributions (with the 3rd par... |
75521fb0fd34163f6610d60a905e2d55eb328d74a0898b67b36dd9c87c61ce63 | ['c6a46b9c8b014747a047263b11a44505'] | As the space of all right continuous functions with left limits, I believe $X$ is not necessarily a metric space, since it is not generally bounded. Therefore, the equivalence between sequential compactness and compactness does not necessarily hold for $Y$.
If you add the condition that the functions in $X$ be bounded,... | d67aab54636a3041c9c5bf9f595b740b8ead958ab52833e5842d029d144f66cd | ['c6a46b9c8b014747a047263b11a44505'] | Here's my attempt:
The symmetric group $S_{n}$ acts on the set $\{1, …, n\}$ by permuting its elements.
Let $n \geq 3$. Suppose $\phi \in S_{n}$ but $\phi \neq e$, where $e$ is the identity.
WLOG $\phi(1)=2$. Now let $\psi(2)=3$ and $\psi(1)=1$ Then $\psi(\phi(1))=\psi(2)=3 \neq 2 = \phi(1)= \phi(\psi(1))$.
Note that ... |
3e54df493a3d259b31cccb36c871cd9ff4b56738c98086c089ce56e82938c7f2 | ['c6b315cd5e924b168e7b5aa3a046544e'] | We have a blob storage that we are putting MP4 files into. We want to create a function that watches for the incoming files (like a pub/sub), and then using azure media-services encode the file to a wav, and save the transformed artifact to another blob storage container. I can create the job to watch for the files t... | 20274ff1479561f7a5df14ac2f4a6469342d7576abadb9d4af2ecadd966a770d | ['c6b315cd5e924b168e7b5aa3a046544e'] | Here is an example of the SQL I am trying to convert to Linq
SELECT
* FROM assetassignment
WHERE asgn_type = 'trc' AND asgn_id = '54490' AND lgh_number <> 3015097 AND mov_number <>2030782
and asgn_enddate in (select max(asgn_enddate) FROM assetassignment
WH... |
b1b491f39b2f82cb5415f6cf4fa5f01c727873d0735481e7cc447b2e12e4f224 | ['c6b86d6c403347688956ee1d6c9f37f2'] | So I was just told that having this sort of thing visible whenever someone views the source on your front end is insecure:
<form action="http://www.somedomain.com/form.php" method="post">
Basically, that someone being able to see the php file that the form submits to is dangerous. Is this the case? If so, how do I mak... | 81c872ba3a33e0d82537e198c8683b92eff07be6ffc3cd9153d32cc574559df5 | ['c6b86d6c403347688956ee1d6c9f37f2'] | I have two css buttons on my homepage that are have an absolute position on them relative to an image. The problem I'm having is that they load a lot faster than the image does, so for a split second upon loading the page, the buttons are floating out in la la land until the image loads and they fall in to line.
Is the... |
ee0ba47bd624f19317fa6a1ea610ff3d68b9324f93194c29cfc01a06f77fdae8 | ['c6c94f01d4ac4054985ab25fc2b51c62'] | I'm using a simple retrofit call which then updates the data and the fragment observes to it through the view model.
Unfortunately for some reason it just doesn't work. it's like the "postValue or setValue" don't work or are simply gone.
Fragment:
@Override
public void onCreate(Bundle savedInstanceState) {
... | bea05e7325e019e9e5443114763fa007bb78fd2e0a8fb757218009bb7bb9788e | ['c6c94f01d4ac4054985ab25fc2b51c62'] | I have a layout which holds a FrameLayout, which in turn has a varying amount of ImageViews on top of it. (Only one is visible at any given time, and the user can flip/switch between them)
All of the ImageViews are Vector drawables.
When I try to implement the Pinch-to-zoom functionality, I encounter various problems.
... |
cdfb4a44a94f879e4e1447a2a60b88c95e0cf42ac6688cdd3cffa580bd709993 | ['c6d167501afc49c4b26bd24c42a0abe7'] | Hi <PERSON>, I have asked a question to <PERSON> to see if they have a /XF switch, that would cover it.
I presume you meant Teracopy instead of Veracopy in your comment? if so i you can't really just verify / compare with teracopy unless all filenames are the same on the source and the destination. | 4a5158de70a691efd257c0786761f5df5b32c2ccfba0f0f1897730e27c11d2af | ['c6d167501afc49c4b26bd24c42a0abe7'] | Hi <PERSON>, Thanks for your answers . I have asked a question to Teracopy to see if they have a /XF switch, that would cover it.
I presume you meant Teracopy instead of Veracopy in your 2nd comment? if so, i you can't really just verify / compare with teracopy unless all filenames are the same on the source and the d... |
3ced140cd5d0b31ef3ebfc4dddcfb5a8a86975eae697b741e04ef5acb903910d | ['c6f47335bd6a4e1ebedc091ff59ee47c'] | as I can see there is no "memoise_0.1.zip" at http://cran.rstudio.com/bin/windows/contrib/3.0/ . However, there is the "memoise_0.2.1.zip" file.
What version of RStudio IDE are you using? Do you have memoise already installed? Maybe you should try to update the memoise package.
| d9d7ab09330de4ab9d9be1d58ea01b85e6098d33d331618765d80515b1054629 | ['c6f47335bd6a4e1ebedc091ff59ee47c'] | I would like to give a similar solution to crowder's that works quite well for me.
Imagine you have Python installed in /opt/Python-2.7.5 and that the structure of that folder is
$ tree -d -L 1 /opt/Python-2.7.5/
/opt/Python-2.7.5/
├── bin
├── include
├── lib
└── share
and you would like to build vim with that version... |
51bcec2c71bea65fb8ae82768063c601431592dc79f295c321290ce86741b5e9 | ['c6ffacb313c34b1d844ebdfbbeb92df5'] | actually i have a problem using Dialog with content dynamic, when i presed a commandButton i want appear a Dialog, but the content's dialog doesn't appear
XHTML
</p:treeTable>
<p:commandButton value="Add" action="#{showEn.displaySelectedNode}" oncomplete="PF('dialogWidget').show()"/>
</h:form>
<p:dialog... | 8d0e7773c6a28f931c0792a12bfd0445ddfe1acb8cb2334b117220f94669d139 | ['c6ffacb313c34b1d844ebdfbbeb92df5'] | I'm building a app using spring MVC and spring security, when i type username and password i can't navigate to the next page (index). This is my code, please help me.
spring-servlet
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.spr... |
671d99c01c4ea20d9574822c43375ac4c3546a4d730c5cbfefbe90f7a617ee8f | ['c70dca2059cc475ea4d31a9fa1361684'] | I made a mistake. I thought I had 7.2.8 but it is actually 7.2.2. As for the extensions problem:
I solved the extensions problem. My php.ini file was pointed to the wrong ext folder. I updated it and now the correct extensions are showing up on the info page.
Where to update in the PHP.ini file: Search for the [WebPICh... | d039eaa609565300381231b8edbd4f9fc97c68e309a366a689c86554b9459fc2 | ['c70dca2059cc475ea4d31a9fa1361684'] | The system is:
$ \frac{dx}{dt} = \frac{x}{y}$
$ \frac{dy}{dt} = \frac{y}{x}$
If we express both equations in terms of $dt$ we get our first solution:
$ \frac{1}{y} - \frac{1}{x} = C_1 $
I have hard time figuring out how to find the second one. I know what it equals to
$1 + C_1 x = C_2 * e^{C_1 t}$,
but have no idea ho... |
2d64f9846850296429714140d6a60a4a9c62f50f0bd0cd1c55eab98454ecffc8 | ['c7125cc18ede4979931ab1c0a3e22aa9'] | Thanks to @wOxxOm ill made it in this way:
// catch page when triggered by link and browser is already open (firefox) step 1
var lastRequest = null;
chrome.webNavigation.onCommitted.addListener(function (details) {
if(details.url == 'about:blank' && details.frameId == 0 && details.parentFrameId == -1 && details.tra... | 3c852da502b7531c933fafea97c1d98d2a208eca0aaade9e07dd931dd12d1f88 | ['c7125cc18ede4979931ab1c0a3e22aa9'] | I'm searching for an event which triggers when an external Desktop-Software like Outlook, Thunderbird, Messenger App etc. want the default browser (firefox) to open a new link. I could manage with a workaround to catch this event if firefox was closed before:
// catch page when triggered by link and browser was closed
... |
2ba6ccdcd0ed5df6f378559f76474dd9806b8a64cedc2d9aebc2e74df42e95d9 | ['c714f786bd4246a0b9e77d7d45df3a44'] | I have been trying to find a simple way to get a list of all possible char values (i.e. ['\000';'\001';...;'\255']) in OCaml.
In Python I'd do a simple list comprehension like:
[chr(x) for x in range(255)]
However, the way I currently know in OCaml is much less simple:
all_chrs = let rec up_to = fun lst max ->
mat... | 104f2185746aee0e2cce53359403828a707da9034bb90df994657c00780b1bae | ['c714f786bd4246a0b9e77d7d45df3a44'] | I am trying to setup code first migrations for an MVC 5 web application hosted in Azure. The problem I am running into is that the migrations only take place on the LocalDB and not the database hosted on Azure.
Currently I have the following setup. I have the connection string for the local DB in my Web.Conf file as f... |
d2cccba22e151503310034abceab8f8f8833a3b170755bbcb29b3b23a57dab12 | ['c73c3759596a4e9a8ef4755c5de5ea85'] | A suspicious link was opened in my Chrome browser and it began downloading files automatically. I'm pretty sure I didn't click anything, so is there a way for me to view how a link was opened in Chrome? (ex. google.com - address bar, example.com - redirected from gmail.com)
| 55df425a5c2c28884af22aee253a44d0de120627c4233161c367aa6fa13f8419 | ['c73c3759596a4e9a8ef4755c5de5ea85'] | I got this settings to work correctly by clicking the "Reset to default size" button. It automatically set the Preferred Size to half the width and height of my original image (since my 'default scaling' is set to '2x' in File->Project Settings).
To keep the button size intact while adding text then set the 'max size' ... |
b3b6fd8d98b987c0d0cb12d5db81bbc78b3874a3fe280ad0ec2328f6fca262fb | ['c749174def4d4aba913738f206572569'] | I am attempting to comment several entries in my [/etc/hosts] file using sed. I have the following command which works great:
sed -i$(date +%s).bak '/devops/,/devops/s/^/# /' /etc/hosts
My problem comes when i re-run the script containing the above line, my commented lines get a new comment. How can I add th... | b2b34d588fcaf981f44c25c4aa81012130fd73f810a2362f5060bdbd4b0345d3 | ['c749174def4d4aba913738f206572569'] | This is caused by <PERSON> pre-fetching the yum repos.
If there are more than one repository with the same label you will see your already defined error when puppet is set to use Yumrepo. The error will show the first duplicate alphabetically and abort.
You can reproduce the error following these steps: duplic... |
e288cdf72f1559350dcf7088b30138a0bd53ff55e850a911e95fc4703ae4166d | ['c749181cd57140c6b7fef69ba1da9ee9'] | Answer to 1) This would work fine for polynomial of degree 2 however, what if the polynomial is of a high degree, like 15, try solving the equation after differentiating that.
That is when methods like gradient descent, golden ratio methods, newton's method etc come in handy.
2)I am not sure but I think you are referr... | a8d02e552a347246e6bb78d482286cf62f7875ef322bccfb4f654d9b8bac4537 | ['c749181cd57140c6b7fef69ba1da9ee9'] | I think the issue you are having now, is that DNS and Netbios. You should be able to connect via IP address. Computer name will not work since Netbios does not broadcast beyond local subnet. You could avoid this if you setup WLAN as a layer 2 bridge mode, that way your LAN and WLAN are on the same subnet. Otherwise... |
08acb3c3f09d76f0cf294d9dd655744f78cfb94a3f6ad006d89191bae7b024dd | ['c7541ccc06404bfcaffbc37f2d6d74d2'] | This is an interesting answer because I can really see how my question was incomplete or too vague. More in details I'm trying to write this game in a web environment, where a loop is not really a viable solution. I can see how an event loop could fit instead. | a2a94e6bba29b83999c6454015f37900132ed8a4e81146d1d8d9f94e11fbfb95 | ['c7541ccc06404bfcaffbc37f2d6d74d2'] | @techraf You are right. I didn't check the error output: *override rwxr-xr-x root/wheel restricted...* properly and didn't realize the missing l...! I'm not surreal - I'm <PERSON> and I will send my new VW Diesel Death Star if you call one of my answers surreal again! |
a9f40b0509c32f18b53b9cd1017b1b1a4af3d070f69ca4a98d38382dacdad607 | ['c7568fc8dc0941bb8ef562481af2f093'] | I am trying to setup various Jenkins pipelines whose last stage is always to run some acceptance tests. To cut a long story short, acceptance tests and test data (much of which is shared) for all products are checked into the same repository which is about 0.5 GB in size. It therefore seemed best to have a separate job... | f52e19e387f080a5b964db4ddade7df651d1c7b27fdcdf6a119409f802b00e2a | ['c7568fc8dc0941bb8ef562481af2f093'] | A fairly simple answer that occurred to me after posting this is to simply break up the timer into multiple sub-timers, e.g. having 10 6-second timers instead where each one starts the next one in a chain. That way, if I get suspended, I only lose one of the timers and still get most of the wait before timing out.
This... |
349a27e78db40b8581762f8c92f7d05ea7b355ba57afcd5f8117028e53b31e0c | ['c7578bf7c7664f5685a5f96355bee10e'] | I thought so, but where is the problem in the proof? Where we jump from the summation to m to the summation to infinity? Or where he adds the terms down to $|x_2-x_1|$?
EDIT:
Nevermind. Don't add all the extraneous terms, and factor out a $\left(\frac{4}{9}\right)^n$ | b27f786d9755f97b65ccf03addb2b7f1c79aabe3fd0be7c5facce83e6db9ad0b | ['c7578bf7c7664f5685a5f96355bee10e'] | Just to confirm, the reason we take these limits is because the nth coefficient of the laurent series is given by $\frac{1}{2\pi i}\oint\frac{f(z)dz}{z^{n+1}}$ which equals the residue of $f(z)$ at $z=0$ which equals the nth derivative of $\lim_{z\to0}\left( f(z)*z^{n+1}\right)/n!$... correct? |
4561d31f1f91a27cc932b61e046f23fa9d6777c3737ab2980eb7518f57c5d541 | ['c76731bb40524b78a9facd71606cf29a'] | I've tried both codes and I think that the problem is data reading. Here follows my test codes.
Sender code:
void setup() {
Serial.begin(9600);
}
void loop() {
Serial.println("A"),
delay(1000);
Serial.println("B"),
delay(1000);
}
Receiver code:
int data;
void setup() {
Serial.begin(9600);
pinMode(13, OUT... | eeb8b1dd7d02f3045909eed6088c186e714461921b92331791019157d12751ef | ['c76731bb40524b78a9facd71606cf29a'] | Grab the audio is no problem, you can use one on the many (and cheap) Bluetooth Transmitter / Receiver with 3.5mm audio jack. You can configure those devices to either send or receive signals, it this case it will redirect audio from the audio jack to bluetooth. The thing that is more tricky is determine which bluetoot... |
91e7ba5332c03d569f3350f79b3909c0b0ac3bb3d7a8c4191a178365221e4aa3 | ['c76ca4fbf24a44b096c97d13514f7227'] | I have a data frame consisting of names of preprocessing methods.
*Impute* *Scale*
naomit noscale
knnimpute noscale
naomit scale
knnimpute scale
In step one function g() executes the methods row-wise to create a preprocessed data set. For first row: identity(na.o... | d342ec440662d5a6bbb1439fd7e1af1a3fff3e648853825326af965c3a2b73c0 | ['c76ca4fbf24a44b096c97d13514f7227'] | I would like to use package arules functionalities in my package but can not
import the whole package due to name conflicts. object@datafr is a data frame that needs to be coerced to transactions. How should I deal with the second line in the code below?
showrules <- function(object, support=0.05, confidence=0.5){
com... |
380cc2491f6a8ad0ebce731d0b03f4bbe0156a63dbbb54fef64a58d1ab31f013 | ['c76cd84a6178490eb30062e365caeb40'] | you can't use the css approch used by leaflet on openlayers, the D3 + openlayer basically draw the data using d3 on a canvas wich is used as an imagelayer.
You need to use the openlayer approch : layers + style , you can have similar performance with openlayers "imagevector" layers.
i edited your jsfiddle with style + ... | 0e6042a4342b195266eadd653ea7abe2f35a5ec8c3965ba7e7f7a66972821964 | ['c76cd84a6178490eb30062e365caeb40'] | Not sure that it is possible, Openlayer can't draw between two instance of the world!
I you deactivate the wrapX function you can see what he see:
http://jsfiddle.net/davidhequet/dkk2yu3L/3/
var vectorSource = new ol.source.Vector({wrapX:false});
vectorSource.addFeature(polygonFeature);
var vectorLayer = new ol.layer... |
7400bcd4ca2772a9bfb0e7d2aac4d19243a6f2d2ea79f9ff63685e7bc2e3b88e | ['c783daf4a0e4488795c5baef91e889d1'] | I have created a docker container for PGbouncer.
(Docker image from - https://hub.docker.com/r/edoburu/pgbouncer)
docker run -d -it --name=pb -e DB_NAME=events -e DB_HOST=localhost -e DB_USER=postgres -e DB_PASSWORD=postgres -e LISTEN_ADDR=<IP_ADDRESS> -e LISTEN_PORT=8083 -e AUTH_TYPE=any -e AUTH_FILE=/Users/nandeesh... | ae333ff6cf200997c78e63d07ab91c63a1ffa94b2a1ff127c2ace0f4238e56cd | ['c783daf4a0e4488795c5baef91e889d1'] | My Project is on spring-boot-starter-parent - "1.5.9.RELEASE" and I'm migrating it to spring-boot-starter-parent - "2.3.1.RELEASE".
This is multi-tenant env application, where one database will have multiple schemas, and based on the tenant-id, execution switches between schemas.
I had achieved this schema switching us... |
4a69c012778995a52943ec777aec2ca14af23bafffea0a5dfbb8c0162c537c09 | ['c79c7ebb8ae9401784c3adb7c59346fb'] | I'm new to unix and trying to create a guide for users to install subversion. I've found a tutorial about how to build from a tarball. I'm ready to try it out, but I don't know how to download the file from the command line from a web address. Can someone please provide the command I would need, and also which direc... | da4dd4881a171b9ea0e5ed49d756a4b530bcbe1d3a8132dd0bcfba9ad6a5d455 | ['c79c7ebb8ae9401784c3adb7c59346fb'] | I've got a 1-line batch file that runs a pantaho etl job. It works fine when I run it from command line or gui, but the process doesn't even start when it's scheduled. I have the following settings:
-Run whether user is logged on or off (Do not store password is NOT checked)
-Run with highest privelages
-Trigger is s... |
9967d7b45fbe8ce84af108fd639e1b707c428256c7357762cf536bb7232be5a2 | ['c79ce70d344a41f7b6ee7651e2a0db0b'] | @Santanu <PERSON>:
Thanks for reply..it is working fine for me too but when same code is called from process builder then it is not working.. I checked the logs it is inserting data but i think it is getting rolled back..I have written process builder on Knowledge object(__kav).. | 812255bec93688a4aa40fd75962a555dce0ba0a43e5b47c9758670b85d91ca46 | ['c79ce70d344a41f7b6ee7651e2a0db0b'] | I don't think so. My impression of <PERSON> is he is very childlike in his mind. I felt that he just wanted to keep the ring to himself because of a childish possessiveness, rather than some innate knowledge to keep the ring from <PERSON>.
However you do bring up a good point. Unfortunately the only way we would reall... |
481dfe469860da812f01d830d500c0bc1b4ce313ce71be94dc6e3d85601919ee | ['c7c5dd2a8e3e43709f9a15d796760e64'] | I think I have managed to upload an image via AJAX to a PHP file, I am now trying to move it to a known location, here is my code:
$allowedExtensions = array('JPEG', 'JPG', 'PNG', 'GIF');
$temp = explode(".", $_FILES["image"]["name"]);
$extension = end($temp);
if (in_array($extension, $allowedExtensions)) {
if (fil... | 4861138d2d815341df513c41391e8bb183590c6d10316bd1ad49a1ca2ac69bee | ['c7c5dd2a8e3e43709f9a15d796760e64'] | I'm trying to write a program that reads an integer n from the user, then reads n integers (on separate lines), and finally display the sum of the n numbers read.
Here is my code so far:
addNumbers <IP_ADDRESS> IO ()
addNumbers = do
putStrLn "Enter a number:"
num <- getInt
addNumbers2 num
addNumbers2 <IP_AD... |
e74f5936ad1f6b0205487b1e5d42bab9cd60f87e2fc23fc4f5d8c521613669ac | ['c7e32616209645fd86e09992cb211416'] | Users currently upload multiple images to a folder on my EC2 server. They will get multiple views by numerous users.
Should I be uploading all these images to S3 instead via the SDK and then load them via CloudFront to increase performance when they are viewed by other users?
http://docs.aws.amazon.com/AmazonS3/latest... | 5f6404db356dd6e8a08f43c11500bfe1399bf060f4d77d9f890bb87f80d767f3 | ['c7e32616209645fd86e09992cb211416'] | After joining two tables I have duplicate column names. How can I differentiate between the names and extract the data in PHP.
Services table:
+----+-------+--------+
| id | price | userID |
+----+-------+--------+
| 1 | 435 | 33 |
| 2 | 543 | 32 |
| 3 | 7646 | 33 |
| 4 | 7966 | 31 |
| 5 | ... |
90aa49fcf67fa8fc75e5247e673518d9a8c98e39ef1609dd8b40d840814a612c | ['c7f1d058c37248b0a4e8d81151c03ad7'] | I tried this way, and it worked. Need to wrap the Icons in a div and it will work.
<List>
<ListItem style={{ textAlign: "center" }}>
<div>
<NotificationsIcon color="primary" fontSize="large" />
Activity
</div>
</ListItem>
<ListItem style=... | 55736d6bca920b1ab04c5bc550e55f9df52a3fe890a4d98549be5bc914831dbb | ['c7f1d058c37248b0a4e8d81151c03ad7'] | I'm trying to create space between each rows of table component. I used classname and classes props on TableRow, TableCell, TableBody and Table, but nothing worked. I also tried to create custom theme but it also not working. Here's the code,
const useStyles = makeStyles({
table: {
minWidth: 650
},
tableRow: ... |
2d69eb3275facab13e98ebb8d6ba538373ad8b80338303a8a8e3de48b3283c8b | ['c800e73907f24af18383e470340cd94a'] | Given two positive integers N and X, where N is the number of total patients and X is the time duration(in minutes) after which a new patient arrives. Also, doctor will give only 10 minutes to each patient. The task is to calculate the time (in minutes) the last patient needs to wait.
Input:
The first line of input con... | 3399127396fd8c5b95be16d31616c160f735376686c4d22cd12aa3f0556fcf52 | ['c800e73907f24af18383e470340cd94a'] | My client requirement is... instead of process portal using the URL they want to launch the process and access the task from their own portal.
For that CHS I exposed as URL and using that URL client portal they can able to launch the process but they cant able to process the task.
When I am framing the URL for processi... |
186ca8983a204e1f6ac1b2f4bb02391880836e1536eb5c2b4528c50072ecef04 | ['c80136cbdbfc496ea81ddcae6083c809'] | I have an app that already many activities and class. Like Profile, Friends, Photos, News Feed, etc. I want to integrate that sliding drawer into my main activities. in the examples, they are just showing array list which is implement onClick. so my question is how to change that array list to become my activities like... | 16073288595e248238acaf90f2693789e367811986bc7f815ca7c3fa45ca306b | ['c80136cbdbfc496ea81ddcae6083c809'] | I am using dual panes2 source code from <PERSON> in his youtube channel. And i added <PERSON> slide menu in it. i change main menu into hello world and added slide menu in it. but when i click item in the list fragment. it switch only into the slide. not in the main activity. how to switch it into main activity. here i... |
8736fb294e2cc2ae41ad472c3b200186652e1c0ab8d28b4b4c490cdb8bc86858 | ['c8180e2a91e74a6d94128c95251ff24d'] | So I am running a service (Jenkins) that is trying to write to a folder on another machine, but it fails with apparently a permission error. A normal user can write to the shared folder just fine. People say to give the Local System Account write access to the remote share, however, I don't see how to do that in a work... | caf0b44be3caefd09b71c8a09a39f7d2239fbb136369f71459d870b727438d03 | ['c8180e2a91e74a6d94128c95251ff24d'] | Lo que veo desde el principio es que desea cargar una vista y no llamar a un controlador. El mensaje de error se debe a que CodeIgniters Router busca un controlador de "view". Dentro de ese controlador está intentando llamar la función de "layout". Esto se debe a que el esquema de enrutamiento predeterminado de codeign... |
41278281d53ed6e3921e82f66a4c783e4cbcac466a1106bcb254dbacc95dea62 | ['c8183c8241fc44ef864d028ff82f8e99'] | Пробую Ajax аутентификацию.
После ввода данных прохожу аутентификацию
user = authenticate(request, username=usermame, password=password)
После логинюсь
auth.login(request, user)
Первый запрос делает все ок, пользователь аутентифицируется.
Если я делаю 2-й запрос на аутентификацию чтобы проверить что пользователь уже ... | 953cd65771309a70a975862107bf9eee3c01c6e9f84bf3f717096ad580342563 | ['c8183c8241fc44ef864d028ff82f8e99'] | When criteria doesnt match in vlookup it returns #N/A and "IF" condition doesnt know how to handle #N/A.so it ends in unexpected result like #N/A......so what i did is correct in my answer i handle that #N/A....and you're mention instead of result, formula is displaying.....so open a new excel by press Ctrl + N from ol... |
886a707c201120e07e7aa07f4b487eea07349acc870191efae1f22a5567383fb | ['c81a79dd051f42fb82c7a8c92f5d4557'] | Hi I have this error when try to run a command:
sudo ionic cordova run android --prod --release
Error:
ionic-app-script task: "build"
[16:58:40] Error: Metadata version mismatch for module
/Applications/MAMP/htdocs/collaborazon/WORKSPACE/mobile/node_modules/@ionic-native/core/decorators.d.ts,
f... | 1a69164cb822439a755521614287f76e0f995b4080d452ef4fe805e1fc396dbb | ['c81a79dd051f42fb82c7a8c92f5d4557'] | I am setting up a new project and I want to use gates and policies. I know how to use it by Laravel documentation but I want to go furthermore.
We have a boot method in AuthServiceProvider where we should define gates and policies.
Can we define controllers in gates something like this?
Gate<IP_ADDRESS>define(SomeCont... |
df8b6c856bd8f140a2142d14ad6097460ff3905716d628c7ab95f1cd544329b0 | ['c81f827e7b834c5e89a31fb50aee9397'] | As long as you have a primary key on the table, this should work:
UPDATE MyTable SET ColA = ColA + 13
WHERE PKField IN(SELECT TOP 2 PKField FROM MyTable WHERE ColA = 5)
NOTE: You may want to consider an Order By clause somewhere in order to make sure you're updating the relevant 2 records.
| 1d0f827106fe21f498fce3995ec72f08c4c916e753012c06cf6088e37adf1dea | ['c81f827e7b834c5e89a31fb50aee9397'] | Provided the field names are the same in both tables (except for the ones missing) you could write some code to do it for you. Use the TableDefs (http://msdn.microsoft.com/en-us/library/office/bb220949(v=office.12).aspx) object to loop through tables and look for "_a" tables to append to and create the INSERT statement... |
809bb5eb47c55d938463aadaeb8dd1be3d6621b395e853aaccfdf61dcfdbd02e | ['c83615790efa4f2baceb3ba81af224c6'] | Let us simplify the given equation in the following way:
\begin{align*}
(n+3)f_{n+3}−2(n+2)f_{n+2}+(n−1)f_{n+1}+2f_n&=0\\
(n+3)f_{n+3}−2(n+2)f_{n+2}+(n+1)f_{n+1}&=2f_{n+1}-2f_n\\
\Delta^2(nf_n)&=\Delta(2f_n)\\
\Delta(nf_n)&=2f_n+K
\end{align*}
where $\Delta$ is the forward difference operator and $K$ is a real constant... | a8fd8540099eedd8da6844bf1a372fa9898def78120af97a1e4a79de0a9d3993 | ['c83615790efa4f2baceb3ba81af224c6'] | Your new progression is given by a reccurence relation
$
y_{n+3}-y_{n}=12
$
with $y_1=2$, $y_2=5$ and $y_3=8$. It is not hard to show that the general formula for the sequence is
$
y_n=4n-3+\frac 1{\sqrt 3}\cdot\sin\left(\frac 23\pi n\right)-\cos\left(\frac 23\pi n\right)
$
|
da6edb1bb35c4f19f84534fecadb39d12f2733bef396b941cb9ead132983b3d1 | ['c85cd02a5efd422a87a68ceeccb48c72'] | Add this dependency in your pom.
Check this link:
https://www.baeldung.com/spring-rest-hal
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-rest-hal-browser</artifactId>
</dependency>
It will change your response like this.
"_links": {
"next": {
"href": "http... | 80e709773e5240fe21f7c81c8ab6eb72fc78170f712181919064c2b4c4cb1cb1 | ['c85cd02a5efd422a87a68ceeccb48c72'] | The reason is you are trying to get the commentList on your controller after closing the session inside the service.
topicById.getComments();
Above will load the commentList only if your hibernate session is active, which I guess you closed in your service.
So, you have to get the commentList before closing the sessio... |
59fb66f790b773369ad55bf6266062dcae0bb42cdee8e89bde73d1472b113233 | ['c86dbe7618504802bb18b251df823eb9'] | Be very careful with the Excel MOD(a,b) function and the VBA a Mod b operator.
Excel returns a floating point result and VBA an integer.
In Excel =Mod(90.123,90) returns 0.123000000000005 instead of 0.123
In VBA 90.123 Mod 90 returns 0
They are certainly not equivalent!
Equivalent are:
In Excel: =Round(Mod(90.123,90),3... | f341dbe3e7eecad3f91b3bec6aeb106c7603b49200abad625b11964c3cda64b7 | ['c86dbe7618504802bb18b251df823eb9'] | If you are happy with blanks in the listing try this in sheet2!A2:
=IF(INDEX(Sheet1!$B$2:$E$5,MATCH(A$1,Sheet1!$A$2:$A$5,0),ROW()-1)="x",INDEX(Sheet1!$B$1:$E$1,1,ROW()-1),"")
Just copy the formula over range A2:D5
|
6cbd940c2523dfe9b282ec14904aff1b58cf931bb30385c11240d40db2c20a8c | ['c88f84bab1474375bbd1ef98d527f24c'] | Can you use member? to do what you want to exclude your patches? Eg:
to-report highest-value
let available-destinations edge-patches with [ member? self blacklist = false ]
report max-one-of available-destinations ([benefit-to-me / cost-to-me])
end
I can't really test that without your setup an... | ee4981d4e51389d0c99acfd75d7c4b7068a155407dd64e1134176225bf147040 | ['c88f84bab1474375bbd1ef98d527f24c'] | If you just want an angled single-lane road that joins the highway, you could try something like:
to draw-merge
ask patches [
if pycor < -3 [
if ( pxcor < pycor + 7 ) and (pxcor > pycor - 1 ) [
set pcolor black
]
]
if pycor < -2 [
if ( pxcor < pycor + 6 ) and (pxcor > pycor ) [... |
ca02a66144d3befc9b12e2742e6fb5e8a19f11bc3bfac3c575725d51a3aa121e | ['c899b936f14e4063aa4c98bc8dbac4e0'] | You might want to have a look to Box2D
I had to take care of a game with some collisions in the past, but it was in Java so I could work perfectly with awt.geom library, which is not available in Android.
Another approach would be to work with Rect and detecting collisions with "contains" and "intersect".
| 8d23664f83234c227780f8c2ef02b3ef196ee5e3ea84ffabfe7bdc8fdbba5589 | ['c899b936f14e4063aa4c98bc8dbac4e0'] | App Engine allows up to 1 write per second within the same entity group. To surpass that barrier you have to have 60 x 60 x 24 = 86.4k registrations on the same day, which I think you can live with.
If you still think you need any faster process you could use sharding (more typically known for counters - https://develo... |
78859786e93ab096c19c47221f084917cf3874581d177fc6259304e2cb51eac6 | ['c8bdffdf058e48da937bce3a0994610f'] | You can do this without the use of a secondary program. Follow these steps:
Set your game to Windowed mode
Have another program open, like Calculator
Switch to Calculator and drag the program window to the bottom corner of your desktop to get it out of the screenshot
Switch back to GW2 and hover your mouse over the it... | f94e902325516a7037adeaf980af97ce44eb718b55677327c34a0ac9235bd158 | ['c8bdffdf058e48da937bce3a0994610f'] | There is an ip conflict on that subnet with that host ip address. I'd bet my life. :)
check arp tables on other hosts that know that IP address. Look closely through all host configurations. See if there is a network interface that has an IP address on the port but not in the configuration files.
Then again... ... |
d0988797588bcdbe3610283ca675e8fcea4d16c470a19d82e0a287423a07cdfc | ['c8c2df9f638b4587a7198bce1f9ce084'] | Здравствуйте. Подскажите как отследить изменение в адресной строке, изменить или удалить из нее часть, и обновить страницу с новым урл?
Зачем нужно. На странице используется AJAX фильтрация, формируя вот такой урл
site.ru/sapogi?page=5&filter=59
Нужно вот эту часть page=ЛЮБАЯ ЦИФРА& привести к виду page=1& или вообще у... | 80572dd5690555b45036a066ee914652df01f095e1e235625147132390613183 | ['c8c2df9f638b4587a7198bce1f9ce084'] | I have an Access database that I inherited and am trying to add some search functionality to it. This is simply a database that holds patient records such as name, address, phone etc. What I want to do is search by last name and have the rest of the form populate with the information.
It may be worth noting that, for s... |
0810b285f2f337add912ba3f73a06ca86704095f4ac4c490045a5efe6ddae113 | ['c8c369dead074da08353995ae17698ac'] | I want to find the string present in one file if present in another file or not.
For example: file.txt contains->
IamLookingforthispatternpleasehelpme
pattern.txt->
thispattern
<?php
if(strpos(file_get_contents("file.txt"),file_get_contents("pattern.txt"))!=FALSE){
echo "found it!!";
}
else{
echo "not ... | 118910a78ef796737ad6e33cc14ca049907ec2631ae8e41c0bbc24b2e264e6e9 | ['c8c369dead074da08353995ae17698ac'] | I have two tables for example "first" and "second". I had to limit first table data to 10 and then join the second table. Both are very large. I joined them and then apply limit after the join. And then fetched the results.
$select = $db->select();
$select->from(array("f"=>'first'),'*')
->join(arra... |
69f830ef3d5932a362a04447721590e495fe80b95805edf6bc86a0a3fa15859b | ['c8c3e4aeee4d4e32ab4db48a7c862f90'] | To troubleshoot firewall I use:
netsh wfp show state
this generates xml file for all the dropped packets and firewall state.
the problem is that this file is 13 MB, and it keeps growing each time I run the command.
is there an option to clear the sate of WFP? maybe I should disable something somewhere, but what?
I have... | 2a73df01199f26a301703ceb32d28112f605df679fbbeb8ff0e6b04dc01e50e5 | ['c8c3e4aeee4d4e32ab4db48a7c862f90'] | Unfortunately not, however I've learned that this file contains all the filters from all policy stores in addition to audit entries, which means you can reduce it's size by reducing the amount of firewall rules applied to active store. and then also disable all auditing. I didn't test it yet, my file is currently 100MB... |
dac155d5cdf40b69f6de0185da0583af6ab8b98c90e76c3bbd49f574ddb96916 | ['c8c830d3f0374c5e89e3967523c812f5'] | My network has an exchange server and an apache server hosting a web site.
Exchange is 192.168.1.10
Apache is 192.168.1.12, secured with SSL
Router/firewall is 192.168.1.1
My external static ip address (for example) is <IP_ADDRESS><IP_ADDRESS>
Apache is <IP_ADDRESS>, secured with SSL
Router/firewall is <IP_ADDRESS>
M... | ab69e67cd6cba3a647665423d053177135becd04f03913a7d941f1f460f30a13 | ['c8c830d3f0374c5e89e3967523c812f5'] | I need to allow both Exchange (2016) traffic and (Apache) SSL web traffic to the same server (Windows 2016). Both require a port forward on 443.
I have two incoming internet connections, both ADSL. eg 100.100.100.1 and 100.100.100.2. I can combine this into one router/modem so they end up being routed from the same dev... |
1b5e3048f6c754dd7c538a08da71f89a96f5dec3a9378032ee03eb3d3b984591 | ['c8d40e8b508b49d3a8f01acca4ccd00d'] | 1.way
LocalDate ld = LocalDate.parse(reservationDTO.getReservationDate());
2.way
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
LocalDate dateTime = LocalDate.parse(reservationDTO.getReservationDate(),
formatter);
3.way
LocalDate localDate = LocalDate.parse(reservationDTO.ge... | 534feeb3cb1a106cc4a2ee92c29bfd950b03a4b2a409d7cad2f6164d26904a07 | ['c8d40e8b508b49d3a8f01acca4ccd00d'] | I have for example that time "15:00:00" and "15:30:00"
firstly i do split and cast to Integer
const hour = Number(this.time.split(':')[0]);
const minutes = Number(this.time.split(':')[1]);
and later i using for example if(hour > hour1) { .... }
I know that this method is not optimal is some tips to compare time?
|
e5ebfe1b9735b1fa5eef8821e5865242bd326deb32390721a3e12be0f6acd5f8 | ['c8d63007892a4477a466813b28af1739'] | The production env files are NOT into source control, only the local ones are. At least that is the intend, production env files should not be in source control as they contain secrets.
However, they are added to the docker image by docker-compose when you run it. You may create a Docker machine using the Digital Ocean... | 2d8d6cdf4ae6118ad2d590b015e9a5408fc6cbdcac7292f8f7e6b450fefe3d97 | ['c8d63007892a4477a466813b28af1739'] | When you traverse a FK in reverse, you end up with a manager, and multiple items on the other side. So i.zone.namingzone in your for loop is a manager, not a NamingZone. If you change your print loop to:
for i in queryset:
print (i.zone.namingzone.all())
You should see all the naming zones for your item. You can e... |
1ce7a110091aa867be05ba2bd258e46b8561b0460abf5e566828c974b8992075 | ['c8e535af6b714d139932b7e6a75b0257'] | essentially I have a function which I need to pass to a bunch of values in two different moments (here skipped for practical reasons), hence, I thought need to split all the parameters in two tuple sets after which I'd pass the first set and then the second thinking - mistakenly - that python would allocate all the ava... | 06119283e84e4cd22757b79f201ed7525e76c28c93b7643221871ee96ce51c28 | ['c8e535af6b714d139932b7e6a75b0257'] | so essentially my problem is this, after I authenticate the user with the dajngo built in system, the user switches to the user "admin" instead of keeping the previous user in session. code:
from django.contrib.auth import authenticate
from django.contrib.auth.decorators import login_required
def new_login_view(request... |
144c6627c48450ec7d543b87b5d168ac6ce0a01b86d3e8a27cfbb51777a868b5 | ['c8ee8d5a87a14622a9d7aab7bfbdfc16'] | Now when i click on edit Modal is not opening and database value is getting empty
another jquery
$(document).ready(function(){
$("#form1").submit(function(event){
event.preventDefault();
var formData = new FormData(this);
$.ajax({
url:"upresult.php",
... | 4f2323272c4b7f94762354b7153d43c9b511294883b3044fb8b79cd4c2e5a212 | ['c8ee8d5a87a14622a9d7aab7bfbdfc16'] | Minimum 3 stocks in item_master table should be maintained.
Table: item_master
create table item_master
(
item_no number(5) primary key,
name varchar(10),
stock_on_hand number(5) default 0
);
Table: item_detail
create table item_detail
(
item_no number(5) references item_master,
operation varchar(1... |
7228e2a070dd31d7b4b2f092b3a7bfe7ffcbe7a6959e405011d4c509d9bb6f5e | ['c90c176fecfd4b8fa4c13d27eab681a9'] | I ended up doing two things. One, I started using patch decorator from the mock library to fake the response form systems B. More specifically I use the @patch('requests.post') then in my code I set the return value to "< Response [200]>". However this only makes sure that requests.post is called, not that the second s... | b46f8cff56f6ca70486bf896231e4a073ddaf51766c4e0601cf01ac7140175a2 | ['c90c176fecfd4b8fa4c13d27eab681a9'] | I have a flask app that is intended to be hosted on multiple host. That is, the same app is running on different hosts. Each host can then send a request to the others host to take some action on the it's respective system.
For example, assume that there is systems A and B both running this flask app. A knows the IP a... |
245974cb23436e42669085f794edbf82eb82ee572d4991137cd51349f13fbe7c | ['c929d2dec7484c60940f7a1245c30d47'] |
if I can't download it somehow
You can't or don't want to? Are you talking about the CSS file itself?
There is no way not to download parts of a big CSS file.But if you already know that some of them are unused then delete them from pack. Or if you are not sure, you could determine it on server side - if you have any... | bbf3a2bc5b7af348b7bec6d2294f75514bd8ab13aa058b1c2e64fb2b160615c5 | ['c929d2dec7484c60940f7a1245c30d47'] | If you use a div as a button and an image as a background you can make your CSS like this:
div.divsclass {
border-radius: 15px 50px 30px 5px:
}
So you can set the border-radius in all of the 4 corners, if you want to only with CSS. Or edit your SVG, as mentioned before.
|
fb274609993d6b82fe3c7a0d9981ccb3ec1bb9186806d353dbf7781652ae96d3 | ['c92de60401de4a32a8909face3430d8b'] | The root of this issue is that List.subList() does not copy the List:
/**
* Returns a view of the portion of this list between the specified
* fromIndex, inclusive, and toIndex, exclusive. (If
* fromIndex and toIndex are equal, the returned list is
* empty.) The returned list is backed by this list, so n... | d2b4f05e2c141b2675cd2775ae0964f6c16382bd9376dece1d10e10595fce316 | ['c92de60401de4a32a8909face3430d8b'] | Cat Plus Plus mentioned that this isn't how a dictionary is intended to be used. Here's why:
The definition of a dictionary is analogous to that of a mapping in mathematics. In this case, a dict is a mapping of K (the set of keys) to V (the values) - but not vice versa. If you dereference a dict, you expect to get exac... |
cdb2af5122a12547bd32a21f4cca6cc5bb7f54a19185d8725df76a0482f42251 | ['c94694c0ee63457494fe8aecbf5862c2'] | My steps to fix that in Lumen 7:
install "illuminate/redis" package: composer require illuminate/redis:"^7.0"
install "php-redis" on my CentOS7: yum --enablerepo=epel -y install php-pecl-redis
install "predis" package: composer require predis/predis:"^1.0"
change the redis client to "predis" (by default its "phpredis"... | 2dccac7b7a8742eccde117ab03caf45d14084538a697a62d315ba2864819e670 | ['c94694c0ee63457494fe8aecbf5862c2'] | Just if you don't want to use foreach():
$month_days=array("Apr"=>"30", "May"=>"31", "Jun"=>"30", "Jul"=>"31", "Aug"=>"31", "Sep"=>"30", "Oct"=>"31", "Nov"=>"30", "Dec"=>"31", "Jan"=>"31", "Feb"=>"28", "Mar"=>"30");
$val='May';
$noOfDay = 0;
$month_index = array_search($val, array_keys($month_days));
$noOfDay = array_... |
8628bef380368d2327074457da3b1d41af77b2f8ec86376ccef8fabd92ee221c | ['c94ade4814734d888a174c771033e8b3'] | I have Acer Aspire XC100 with RAM upgraded to 8 GB running Linux (Ubuntu). I am using the system as a home entertainment system to listen to music etc. The problem is, the system doesn't seem to have enough power to run Youtube videos in full screen mode. Whenever I go full screen, the video starts to get out of sync w... | b00df16a4d01d20c26f119de05aaaf8867a2413a5fa123cd0cd980e598afafc7 | ['c94ade4814734d888a174c771033e8b3'] | I am trying to solve a problem of the following form: pick a continuous random vector $(X_1,X_2)$ with support within $[0,\infty)^2$ to maximise $$\mathbb E\left[\sqrt{X_1+X_2}\right]$$ subject to the following constraint: for any $i,j$ with $\{i,j\} =\{1,2\}$ and almost all $x \ge 0$,
$$\frac {f_i(x)}{1-F_i(x)} \ge \... |
fc3355bc5b127140163e44492deb22e161d6f7fc0316eda58384bcbfb890eaa2 | ['c95bfdd362c64167b43e6a370669920a'] | Yes, as long as you keep your database integrity when migrating.
CKEditor basically adds HTML tags and attributes to your data, which are saved in your fields' tables in the database. So, for example, if you have a body field that contains text formatted like "Hello, body", and take a look at your field_data_body tab... | 96d4a320dfc8965af843171b3367939dcd80684950fcb5c3da38cd658ffc799a | ['c95bfdd362c64167b43e6a370669920a'] | Yeah, basically any PHP code will work in the "Computed code PHP" textarea available in any computed field. So you should be fine. Let me know if you run into any issues.
PD. Please note it's not a good practice to include PHP code in a field, but if it's your only option, go ahead. |
d31399e748602b85ee3556ba3d8eb16c844f6f980c9dc8f0173040ad8c1516a7 | ['c95e0e89bf43455c9fd1ed52a9ef7839'] | Here's a part of code I developed to better understand Java gui. I'm also a begginer.
It's three classes: starter class, ongoing non gui processes, gui with the swingworker method. Simple, works, can safely update a lot of gui components from Swingworkers process method (passes a class instance as argument). Whole code... | 24d998577c94f38e6cff6242f1a998f6456395471badd5d3771bb70959a90e10 | ['c95e0e89bf43455c9fd1ed52a9ef7839'] | I managed to send a char to arduino by using jserialcomm library. The method looks like this:
// imports I make in my class
import javax.swing.*;
import java.awt.FlowLayout;
import java.awt.event.*;
import com.fazecast.jSerialComm.*;
import java.io.PrintWriter;
code in method
System.out.printl... |
52b1f0e34451108f4996890ea736b1406eb07df99b13748f202075abe33687ce | ['c96d4271ebc0462a89b9f78646d3dc45'] | This is a follow my rock-paper-scissors program, original post here:
Simple rock-paper-scissors game
Looking for any feedback and recommendations on ways to keep improving.
Quick notes on changes:
Removed the use of using namespace std;
Added inheritance structure.
Added the use of enum variables to replace strings to... | ad5d179c09664b5ed2a3aa38a996f69223b5c58b7cfb4b2c09e182974b6748ea | ['c96d4271ebc0462a89b9f78646d3dc45'] | I'm trying to migrate the data at my company from Excel to mySQL so I'm very new at this. I just installed the latest mySQL package via the standard installer and when I try a new connection (I'm trying to get through the mySQLTutorial) the error pops up:
MySQLWorkbench.exe - No disk
There is no disk in drive.
Please... |
3d9c7f3a34106ba88c0d9b29b0f217cbe8d736bd1e1f34016f739decaec3b873 | ['c973f9526ee04853948ad2d541d2bce7'] | I cannot get date ranges to work properly in a query using SQLite3
Create And Populate Table:
create table dates(myDate DATE);
insert into dates values('2012-10-1');
insert into dates values('2012-10-2');
insert into dates values('2012-10-3');
insert into dates values('2012-10-4');
insert into dates values('2012-10-5')... | 41da1cad0e442435e9bbb24882f241a546066a1868a04e647356ad2138da865a | ['c973f9526ee04853948ad2d541d2bce7'] | Huge thanks to thedoctor
After enabling logging, I noticed the issue. In Location,
@PrimaryKeyJoinColumn(name = "locationId")
Was incorrect. JPA was trying to join the EventLocation by matching the Location.locationId with the EventLocation.eventLocationId. It is my understanding that JPA does not allow joins on f... |
82d118fae44b3d0fcee228e2904d23c71e5a4fd4a3006f16423d0896da1d282b | ['c97c240a97ca4dabadc16a5803034921'] | Having some trouble getting a valid JSON output from a php for loop, here is my JSON:
[{"title":"One Colour ($2.45)","price":"($2.45)"},{"title":"Two Colours ($3.35)","price":"($3.35)"},{"title":"Three Colours ($4.25)","price":"($4.25)"}],[{"title":"One Colour ($2.45)","price":"($2.45)"},{"title":"Two Colours ($3.35)",... | 7cbf1cb6025b9d63b7c5a91b4a74d5a64909b12a014f388c93a1398ff00cf34d | ['c97c240a97ca4dabadc16a5803034921'] | Thanks for the help everyone. I ended up coding this (works like a charm):
<?php foreach($loterms as $key => $loterm) :
$brand_id = substr($loterm->name,0,1);
if(ord($brand_id) > $index_temp):
echo '<li class="full-width">'.$brand_id.'</li>';
... |
24e804e840d4b28ebf0d6fd5b2c817849d5a34fe518c0c50f91180a28ae2ca32 | ['c98598c367044f2ca34da7edac5b18fa'] | I realize this post is old but I ran into the same behavior today when importing a json file. The issue was the .json was not properly formed. It was missing the [] (square brackets) at the top and bottom of the file and the ',' (commas) between the objects. I validated the file using http://jslint.com/. The error was... | 1ab1fbb39b37394b8bfd512b5460b65cbbdc64c2f4f0643c644a8e8d96e39ad9 | ['c98598c367044f2ca34da7edac5b18fa'] | I have configured the superfish block to display on all pages EXCEPT the user-login page but this is not being honored. I've also created a superfish menu block with no menu items and have configured to ONLY show on the user-login page but this is not being honored.
Why am I trying to do this? There are 3 dummy menu it... |
4fe3f737367a841e5205c8f2bd7bc01016c23f5080e0f26f15b57e506fd0d0cf | ['c98f4a70e1f54aec982e07c77b473386'] | NameSpaces from the request XML need to be used in xslt as well.Following xsl gave the PartNumber value.
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:regexp="http://exslt.org/regular-expressions" xmlns:s="http://schemas.xmlsoap.org/soa... | 2da4f09ca21abd23624107c669212f3517737be469ac3d17968582cba53fce9d | ['c98f4a70e1f54aec982e07c77b473386'] | I'm trying to update the text nodes in xml based on the check if it matches a certain pattern
in xslt 1.0
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:regexp="http://exslt.org/regular-expressions">
<xsl:output method="xml" version=... |
da26b0e4669c40cb06e8fbb3b949a08f32e950fd9b16cc0931b59cb33cc2ae7e | ['c99072d0c72e4542b9cee8d8d5546ed5'] | The fastest is is join to the same table.
http://www.postgresql.org/docs/8.1/interactive/sql-delete.html
CREATE TABLE test(id INT,id2 INT);
CREATE TABLE
mapy=# INSERT INTO test VALUES(1,2);
INSERT 0 1
mapy=# INSERT INTO test VALUES(1,3);
INSERT 0 1
mapy=# INSERT INTO test VALUES(1,4);
INSERT 0 1
DELETE FROM test t1 U... | e108478d341ccf8cea2ab65297846465b224a9281127b57d5d34db24a973e174 | ['c99072d0c72e4542b9cee8d8d5546ed5'] | If you really really really want to create own solution. It's my old bad solution before oAuth times.
Create view which return some key after successful login with username/pass and add generated access_key to db
Check key in request => if exist in db => login
#pseudo code
#view
from django.contrib.auth import authe... |
325b8d968b6c6d198ce992fed4442411d922133b4735ded9484abf912baa8867 | ['c994499e912f4b26a5e1a6c66c311006'] | You can use code below.
String full = "Hi 123 it is a 564 and 678, so let's work.";
List<string> list = new List<string>();
string buffer = "";
bool number_seq = false;
int number;
for (int i = 0; i < full.Length; i++)
{
String single_char = full.Su... | 26b6698241e5ff0eb3589570317f8aa5310c5dcd62aa61a1013fcf2a4372924b | ['c994499e912f4b26a5e1a6c66c311006'] | I can explain like below
This is an object
public class Person
{
public string Name { get; set; }
public string Surname { get; set; }
public String SayHello()
{
return "Hello";
}
}
You cannot access directly Name, Surname and SayHello from Object like below,
Person.Name = "<PERSON>";
P... |
e55fb2ab8cb2f03f2d63dbe011013fd27cf52fa56ae967bb64ba2af5b8d1a882 | ['c99ff93f52d0440481ee17b97678105c'] |
<html>
<head>
<style>
#contain_main {background-color:black;
width:100%;
height:auto;}
#main {width:100%;
height:700px;
background-image:url("https://www.sappun.co.kr/shopimages/sappun/0090040002602.jpg?<PHONE_NUMBER>");
background-repeat:no-repeat;
backgrou... | e30362e08c26f9d463d5bb901b628590160e8445ac49c8c31508178e2cdb85ca | ['c99ff93f52d0440481ee17b97678105c'] |
<table cellpadding="0" cellspacing="0" style="display:inline-block;">
<tr>
<td>
<a href="#">
<img src="https://www.rakuten.ne.jp/gold/sappun/promotion/20201231/test_07.jpg">
</a>
</td>
<td>
<ta... |
fee3bf5d891d172ab0c41cd923a6e42f297d82c7c6e92a81b098c5759b7a044c | ['c9b1268bb8804c51aeb342985234ce0c'] | I'm getting an exception which I don't understand in this bit of code here:
Dim folderList As List(Of String) = _folderList
For Each folder In folderList
destinationFolder = destinationFolder + "/" + folderName
localFilePath = lbl_folderPath.Text + "/" + folder
alterFolderList(localFilePath)
...
Ne... | 63dbb46edc0b575134d8a0ac969c57a7825da2cfc59b3f6ed72775b51a7d51b3 | ['c9b1268bb8804c51aeb342985234ce0c'] | The Kendo Splitter has a collapsible property that I want to use. However, the icon is a very small arrow that isn't intuitive at all, the users can barely see it. Even when they know it's there, the icon is so small that clicking it takes some time as hovering such a tiny icon is not that fast.
I want to make it bigg... |
1b18bf93d86670815ea90b1a9fcf477e26b312541eabd30f5e88a1ee9583f8a9 | ['c9b9054c010542cea19dbb75249f10fb'] | "Is there a VBA equivalent to a Getter method in VBA?"
Yes there is, here is an example
Private mSomeValue As String
Public Property Get SomeValue() As String
SomeValue= mSomeValue
End Property
'A corresponding setter method could look like this'
Public Property Let SomeValue(aValue As String)
mSomeValue... | eec625f58bbd0b2fddd302eb231560d76dfa763442950d1d8bf5b2b9f7279d7e | ['c9b9054c010542cea19dbb75249f10fb'] | On windows, it is stored in a sqlite database, in
%Home%\.ipython\profile_default\history.sqlite
If the %home% variable is not set, try %userprofile% instead.
As an example, if you'd like to look back at your very first ipython session, you could run
select source from history where session = 1
|
31ed1cf20ccf4affa5164427a9496602f1774c988be283b4852f60b3e3c3dbd8 | ['c9bca4a7f2a74f72874b714e19a9b164'] | The cleanest way to do this would be to extend phpunit with a new assertion method. But here's an idea for a simpler way for now. Untested code, please verify:
Somewhere in your app:
/**
* Determine if two associative arrays are similar
*
* Both arrays must have the same indexes with identical values
* without res... | b4b00598d6651ea0a22b5696d0d69f850bb32bdb39d33fef1ce66cb255e40c52 | ['c9bca4a7f2a74f72874b714e19a9b164'] | You may also want to look at sending it as an attachment via PEAR Mail_Mime. It can accept an attachment as a string of data.
The RMail package also looks as if it will do the same via the stringAttachment class. You'll have to google for it, because I'm a new user and so I can post only one link at a time.
|
725e76dc93ae924625c70b3056afa4acca395a372f8bd32e03a20a3faff4c687 | ['c9ce3af6db2f4775a12b91e70fbd3bd3'] | I am currently developing an iphone application which is nearing completion but i want to add in the functionality to be able to connect with facebook. I can grasp the basic functionality of this such as connecting and posting status updates and feeds but id like to be able to interact with friends and events within fa... | d8b7596c67400fc5fa4821a40369491701b879232656d938b17cad22c18a5cfa | ['c9ce3af6db2f4775a12b91e70fbd3bd3'] | I am using an if statement to check the value of a BOOLEAN when i click on a button. When the button is clicked if the value is false i want to display a UIActivityIndicator and if the value is true i want to push the new view. I can do this fine but i want the view to change automatically when the BOOLEAN Becomes true... |
eea2019ccf6c14fce841010f590d3a850f0b17a40f4373bde51a8b41fb73bf9d | ['c9db6fc389c24ab1bd92f00d9512cf9a'] | To create a histogram in Excel you would use FREQUENCY
This is no diferent in using something such as the groups for colours.
The difference is that you would use an IF statement referring to the group column.
=FREQUENCY(IF(GroupRange="GroupName",DataRange),BinRange)
So if your data was in B2:B40 and your group delimi... | 9a1b6ee972afa84b4f2f9809fe3b6077228ddd2e02a8a247a96cc0c3fef637a6 | ['c9db6fc389c24ab1bd92f00d9512cf9a'] | You can write to a CSV quite simply using VBA.
An example could be:
Sub WriteCSVFile()
Dim My_filenumber As Integer
Dim logSTR As String
My_filenumber = FreeFile
logSTR = logSTR & Cells(1, "A").Value & " , "
logSTR = logSTR & Cells(2, "A").Value & " , "
logSTR = logSTR & Cells(3, "A").Value & " , "
logSTR = logSTR &... |
1b4889643dbbe67ea3f373dbbc764561b6b572633509657a69dbb2154c153872 | ['c9e5a8131a2a47e4be82f4d9c3ffc7bd'] | Context
I ran an experiment with a two-factor within-subjects design (factor A with 3 levels (small, medium, large) and factor B two level (open, closed), so 6 test condition).
12 subjects have repeated 5 times each of the six test conditions (so 30 test per subject).
I tested for significance using a repeated measures... | d69c1d512505b51092cbf8bc7e8b4f6df7eb229d1f8ec2cabdb9ca8f64e79f72 | ['c9e5a8131a2a47e4be82f4d9c3ffc7bd'] | $args = array(
'post_type' => 'news',
'posts_per_page' => 5,
'post_status' => 'publish',
'order' => 'ASC',
'tax_query' => array(
array(
'taxonomy' => 'week',
'field' => 'slug',
'terms' => $currweeknumber,
)
)
);
$post = get_posts($args);
I have a page which posts 5 news each week. I hav... |
376810b5236195176fc3bc4a2cb9ec3e39b51fa53a32fca03ee7db14cbbc2a2a | ['c9f7afedd11d486c9ee0ac19351210ee'] | I made a 5 second time bar to replace the wave. when wave1 has been 5 seconds it will move to wave2. then the first wave will be destroyed. when I got to wave3, an error came out. here's my code:
IEnumerator ChangeWave()
{
for (int i = 0; i < wave.Length - 1; i++)
{
yield return new WaitForSeconds(5f);
... | 0d0d1b853c7b6072f6db6d7aac7596285c02d4ff125222d2bf52f44f52027594 | ['c9f7afedd11d486c9ee0ac19351210ee'] | so I made a script for multitouch using raycast. when dragged faster, the gameobject will be released, but when moving the gameobject slowly it follows the touch. here the codes
Vector2[] startPos = new Vector2[5];
Touch[] touch = new Touch[5];// Update is called once per frame
void FixedUpdate()
{
Debug.Log(Input... |
dce6b29fca3e49e174d3f1c838f0e228562571aff5b814db9faddf1b9a999ead | ['c9f8dfec53d44404900fb876a4cb602e'] | Basically, this person would be obsessed with their appearance. They would look in every reflective surface they could find, and remind themselves of their ugliness; but always searching for a new perspective.
I guess as a narcissist would look in the mirror 110 times a day and think, wow, I'm beautiful, a (insert the... | 5063dd314c50dbd6964d2e4ad99a83c6586e17f66559203aa41207e8dca6bfad | ['c9f8dfec53d44404900fb876a4cb602e'] | Всем здравствуйте!
Пишу небольшую программку на с# под WinForms и столкнулся с такой проблемой:
У меня есть длинная строка с текстом, которую. мне нужно засунуть в richTextBox так, чтобы она была одна сплошная и прокручивалась горизонтально, но она постоянно переноситься на другую строку, как только полоса прокрутки до... |
bc396578b3bcfe95e11f5c7d86cf0d577352bfad9d68797be861fac7eedfec13 | ['c9fdf9952d794f069e234d80ff3a4756'] | There is a requirement in my application to evaluate string expressions during runtime in WinRT c# application.
Here are some example expressions:
strObj.Substring(10) + strObj.Substring(strObj.Length - 3)
'001' + strObj.Substring(3) + '003'
Note: Above expressions will be defined in the backend and the application ... | 129ad6cd0cd28d0a5abcd8b2c9cb19e6123d8c487f6d42a58bd4af155898c3fd | ['c9fdf9952d794f069e234d80ff3a4756'] | You dont need two connection string. Query you mentioned in ur code snippet need to be run on DB1 db. So your Constr just need to point to DB1 db. Your query will run on DB1 and create a new table Car in DB2 db.
Note: Assumption is that both DB1 and DB2 exists on same server and user you are using have access to create... |
d6bf057436b717b4a4279397fe0559d2c9aea9ee7e35de14a9d861ee03137f48 | ['c9fe67c775de4062a4d315ef0a4b4e32'] | I am trying to broadcast a message to two browsers running the same app using Vue-socket.
When the app is created, I hook a listener for new messages to it like so:
mounted: function(){
this.$socket.on('newMessage ', function(data) {
console.log(data)
})
}
When I type a message in one browser, it's sent to the ser... | 0c31495d1c5f24d9f115c11dfe8392758aeebd3f56153df173f7da42d3923288 | ['c9fe67c775de4062a4d315ef0a4b4e32'] | consider this program:
#include <iostream>
using namespace std;
int main ()
{
int i;
cout << "How many numbers would you like to type? ";
cin >> i;
int * p;
p= new int[i];
cout << "Enter the numbers: \n";
for (int n=0; n<i; n++)
cin >> p[n];
cout << "You have entered: ";
... |
5167e1e61641273158e282c0ad8797cd1e037235926773b7a4670719c9fcf0bf | ['ca0591d7b0d2420f9e3bc656d564f30f'] | I'm trying to write a JQ filter allowing me to selectively filter object properties based on other of it's values.
For example, given following input
{
"object1": {
"Type": "Type1",
"Properties": {
"Property1": "blablabla",
"Property2": [
{
"Key": "Name",
"Value": "xxx"
},
{
"Key": "Su... | 20f43b9cb9b9d35c3cc9a62ccc321b4a2895ac20aed0920741f01f826324554d | ['ca0591d7b0d2420f9e3bc656d564f30f'] | I'm trying to write a JQ-filter for filtering specific resources from an AWS cloudformation template based on resource properties.
For example, when starting from the following (shortened) cloudformation template:
{
"Resources": {
"vpc001": {
"Type": "AWS<IP_ADDRESS><IP_ADDRESS>VPC",
"Properties": {
"CidrBlock"... |
491fee457b69c0c340f0e11bed1b719ee26e0ba9044b820b9b657bdcb16114bd | ['ca175142119c468fb66963514765ae6a'] | I'm trying to figure out with Breeze how to expand a specific navigation property for all items in an array of entities with a single request.
On this page of the Breeze documentation it shows the following way of achieving this:
var orderEntityType = selectedOrders[0].entityType;
var navProp = orderEntityType.getNavig... | ea512c44ed3acaa885abfdf171bc3e7d8bd785df77f588f6f06b4ebbc5f12edd | ['ca175142119c468fb66963514765ae6a'] | I'm working on a monitoring program for our shipping department that will show orders that are ready to ship. I've been working with SQLDependency to do this and finally got it functioning, however, when I try to add some more specifics to my query, specifically comparing to a datetime column, the OnChange event is re... |
0713231c79bf35bf95a1a0a20ebd66a5a1f4ae0506045a316f5e2aeb08a7fc6c | ['ca218a5c6c5f494ebe27edbd26df5a98'] | <PERSON> Isn't the "between 2 points there must be a line" enough for this? I mean, if I want to connect a and b, assume that the proper line goes through the restricted area, then add another point c, outside, and connect a to b, and b to c, and so on. Is it enough? thx in advance | eb237d289c50dc3c7c45564c35b576b9186ed03b1056dd2f50261b010778f8da | ['ca218a5c6c5f494ebe27edbd26df5a98'] | As the title states, I need to find the functions that aren't measurable, but have a measurable set as a source (because the sigma-algebra on my space A, is P(A) ). I know that every non-zero-measure set has unmeasurable set in it, but how can I describe the functions that their image is those unmeasurable sets?
|
38d601384af4fe8317afb9f042ef2314f9d175827169c97452616e83e14ee886 | ['ca4916e583804d7680e0b11f050179ef'] | Anybody knows which Ubuntu Touch version will be trully convergible?
I purchased a BQ M10 thinking use it to work but there's no VNC or RDP client. There's no File Manager with SSH support and none development tool or IDE.
In this time my Android smartphone seems to be most usable. What's wrong?
Thanks.
| 82246e74626445700913fac925aa7ea240b9c536004c4623bf4029322dd89057 | ['ca4916e583804d7680e0b11f050179ef'] | I have WCF service which launches the remote process from Process.Start successfully on stand alone machine where this WCF service is hosted/deployed and developed.
I deployed this as whole service on another machine, and run the service on that machine as well, execute the service on the same code area which launche... |
87f01501d0739e551ffd3594970af10cc9bd9eb5687f1a8a1cad8b3a002ab90a | ['ca52bdc40ea145bfa44ec1843eb08218'] | You might consider increasing the reaction time of your human test subjects. Animals like flies, crayfish, and squid all have significantly faster reaction times than we currently do (see https://www.quora.com/How-do-the-reaction-times-of-various-animals-compare-with-that-of-humans)
This has two advantages that I can ... | 2f4ef22e9477962a96197373af4399fa8fe4018e5467a335acffb30bcc36a36a | ['ca52bdc40ea145bfa44ec1843eb08218'] | I would definitely make sure you have enough bypass capacitance on the power line of your IC. You may have it already but I don't see it drawn in there. Any cap in the low uF range will do (preferably two or more with different values but probably don't need to go haywire for this).
|
07df4532181f8745481075c1bea8ccc4039d11f545983f7be7e70a697182fc85 | ['ca5c1e6e66b34bb2940885f7d20b28ca'] | You could create an object that encapsulates your number and the function?
so:
var groupA = [{
number: 5,
action: function() {
alert('awesome action');
}
}];
then you could loop over the objects and look for the number,
for(i=0; i<groupA.length; i++) {
if(groupA[... | ca584d7a2a51b1ba8fbf2a2ac35660bdf264861e0916577105060cc4a2874a11 | ['ca5c1e6e66b34bb2940885f7d20b28ca'] | The problem is you are inserting a new row each time.
You need to explore the Sql UPDATE statement. Basically what you need to do is insert a new row on login and retrieve a unique identifier for that specific row. When the user logs out you need to update that same row using the identifier and set the logout time ac... |
3234f93cd0d9a59378f2e3278a9ebaaf32ad8b88540a866b2eea1bc5f3475ab9 | ['ca6329bd89cc4cd0881480603fb6b778'] | I,m trying to make a responsive website using bootstrap3 that is 3-column in large screens and 2-column in medium:
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-4" id="sidebar1"></div>
<div class="col-lg-6 col-md-8" id="main"></div>
<div class="col-lg-3 col-md-4" id="sidebar2"></di... | 0761528053e4abf34dac4e406053b5b2a33c7950bf10e3a770b4fe68e676c993 | ['ca6329bd89cc4cd0881480603fb6b778'] | I do it with jQuery.
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-4" id="sidebar1"></div>
<div class="col-lg-6 col-md-8" id="main"></div>
<div class="col-lg-3 col-md-4" id="sidebar2"></div>
</div>
</div>
and jQuery:
function mediumResponsive() {
// Reset everything
$( '#main>... |
267243b9a301d2261e203795edf195e5b45ff42c5b9e8ccf2ecc4bd266dbceb4 | ['ca6be7354d124c55a3c2b54294b77d1c'] | Im using ajax to send data to a php file which executes a query to a database and returns a string.
When im going to print that string in some html object or an alert(), it prints with two line breaks before the string.
Please help me to find why this happens.
Here is the code im using for ajax
$.ajax({
data:... | 1301df510fe2594df0c011907356edf4d2dae93ce860569830ef1110c8aa90bc | ['ca6be7354d124c55a3c2b54294b77d1c'] | The Ocean controlls are under the library Slb.Ocean.Petrel and Slb.Ocean.Petrel.UI.Controls
In visual Studio you have to clic in the Tools menu, and select the Choose toolbox items.
In the show up window, click in Browse and look for the libbraries in the Petrel/Public folder and the controls will add in the General ta... |
559bebc28891106c1590249a6fdf8e43837bffc538a0b595edfc6697cceaccbb | ['ca776bafcbba45e0b87de8175de07c80'] | I am trying to connect an excel file to my C# code. However, the code throws an exception: "'ServerVersion' threw an exception of type 'System.InvalidOperationException'"? What could I do to fix it?
OleDbConnection con = new OleDbConnection();
con.ConnectionString= "Provider=Microsoft.ACE.OLEDB.12.0;DataSource... | 258a446c2732e9ebef517b2dd4ccd051009a74e285606082c0f059e308da37a1 | ['ca776bafcbba45e0b87de8175de07c80'] | I have been developing a tool in which data is copied from the input excel file to another excel file at different column location. Currently, I am using sheets.Range function to copy the data from individual column to another by using a loop for the numbers of rows present(Since there is also some data manipulation). ... |
f5eeabb5af4836acb968cdb7668dcc87e246e638df2ce9ffd6d9c49f508ded6e | ['ca8aad9a1d1c44eca4cd5f9b96b5b6f7'] | I had a similar problem and here is my solution:
<p:panelGrid style="width:100%"> # notice that I do not define columns attribute in p:panelGrid!!
<f:facet name="header"> # header
<p:row> # p:row and p:column are obligatory to use since we do not define columns attribute!
<p:column colspan="2"> ... | 813705a64074970bf9357f77c24a682cec9be3994cba57095c49bcad84928848 | ['ca8aad9a1d1c44eca4cd5f9b96b5b6f7'] | Where is the part of the code in which you update the component? Maybe you could try the following - update the component programmatically inside the method *cmdCreateNew_Click()* like this:
public void cmdCreateNew_Click() {
setTarget(_RULE_DETAILS);
//add this line and check the path to the component
Requ... |
9ab58eb38c83df029f247736ad95b40c99dac281f8c045a05f0ff22f1be9bf4e | ['ca9e4a6ce267457c9d4eb9d2416886d5'] | Hi I am looking for some expert advice on how to break my class up.
Please bear with me this is the 5th week on c# im still fresh.
The task I got is to create a basic database and interface for a fiction company.
The interface shall support basic administration of members of the company.
The only rule is that there sho... | d90ccbfe6219217170ab48b03b350daf22f9e38cb926b47b785063cfeb225de5 | ['ca9e4a6ce267457c9d4eb9d2416886d5'] | I am in no way an expert but I would use isEqualToArray inside NSarray class.
The function inside the class compares the receiving array to another array.
SWIFT
func isEqualToArray(_ otherArray: [AnyObject]) -> Bool
Return Values
YES if the contents of otherArray are equal to the contents of the receiving array, other... |
4a48a5cff203306fea91b6548ff4ac4f464ab0b43c2a75832704a6590af57221 | ['caaa1861a7404650ace0905d458f30b1'] | I've been having a similar issue in Safari 12+, as I was also using padding to force aspect ratios in a grid based layout. I'm not sure if this is exact same problem you were having, but the fix below works for me on your pen in Safari.
TLDR: Put display:grid on the div surrounding your grid container. Here it is in ac... | c7c4229dcd9838c283e3722b51952f01686b6859689d57687a8bc040aa74f1a8 | ['caaa1861a7404650ace0905d458f30b1'] | As someone else has commented, the way to do this would be to use transform:scale(2) on &:hover - adjusting the number as necessary. This should avoid any layout shift, and it will be more performant than animating the width as you are currently doing.
See this article: https://pqina.nl/blog/animating-width-and-height... |
d32d20fe029c37ae2fd5d1c7e8f9a8e50d7d6b9aebbee6bb10ac1427001228cf | ['cae08099c0f64b9db864bc32a4d538a1'] | Looking at your previous question as linked:
Did you ensure to register for location updates like so?
LocationServices.FusedLocationApi.requestLocationUpdates(
mGoogleApiClient, mLocationRequest, this);
If not, your code is likely receiving the last known location once, then not requesting any more updates. Ta... | 47569337051e91e2779e5dd2c2f3071d5f8a4b6393888fac28858a1412b66348 | ['cae08099c0f64b9db864bc32a4d538a1'] | A cleaner implementation with more thorough explanations can be found in the android documentation here:
http://developer.android.com/training/implementing-navigation/nav-drawer.html
That said, it looks like you already have some clickable list items, all you need to do now is start the new activity within your ItemCli... |
61a29da25f3955a3c5e1a9c25b0493b9ce2209c3b150049e3eaf6992e21b29c5 | ['cae8ba7d7d0945d98087445f540fec7c'] | There is an easy fix for this error as per my experience
If you installed metasploit-framework correctly the following workaround WILL work
navigate to the metasploit-framework directory usually, cd ~/metasploit-framework should do the job
Run the same command using 'ruby' i.e. ruby msfvenom -p android/meterpreter/rev... | 692904ddad0982c9ea31952becf4ee3fce7a07786a38ca17180919c1b30cea0e | ['cae8ba7d7d0945d98087445f540fec7c'] | Unlike regular Linux Distributions, Termux does not keep a history of the version updates hence installing Python 3.6 is a difficult task, but it's not impossible, you'll have to build and install python from its source code. Which you can find (for version 3.6.10) here : https://www.python.org/downloads/release/python... |
e6950d56e23614e825f634aca7fd0839cd54c7e7424feab58e5b77e5efced61d | ['caeb01f40bcb4d69940bd68765018543'] | I'm learning java and for a particular application I am creating, I am initializing a 2D array of objects. The particular object that would occupy the array when initialized changes multiple variables in its no args constructor. I am wondering if when the array is declared java initializes each variable in all elements... | c7bb9020b8f0be733d28cff2a9dae8c2f78998e1efef59daec85e42a01280782 | ['caeb01f40bcb4d69940bd68765018543'] | As stated in title I am having trouble proving this. I have been trying to use a proof by contradiction where I assume A^2-B^2 is even and A - B is odd and show how that is untrue. Unfortunately I can't seem to figure this out.
I have tried setting the even expression equal to 2x (implying even) and the odd to 2y+1 a... |
e3a9654ababfd600fbc01f7115259ec6169e59b4a6d486b211ea6a9fc513a09d | ['cb02cf0beed040e7af3f1b288c1c618a'] | I need to create a tab like below.
Using the code as follows i am getting some what near.
<TabControl Margin="-2,0,0,0" Background="#37e8f9" BorderBrush="Red" BorderThickness="0" TabStripPlacement="Left" HorizontalAlignment="Left" Width="261" >
<TabControl.Resources>
<Style TargetType="Tab... | 0f098c0c4c58ca39904781118c485379dffe87cb948264e4bbcc1856b7b98160 | ['cb02cf0beed040e7af3f1b288c1c618a'] | Below is the code for the panResponder in componentWillMount() method.
this.panResponder = PanResponder.create({
onStartShouldSetPanResponder: (e, gesture) => true,
onPanResponderGrant: (evt, gestureState) => {
this.state.pan.setOffset(this.state.pan.__getValue());
this.state.pan.setV... |
543164455db70b29da27a4082662fc1f574825058ad97fce557aef9c230acede | ['cb0d4714f92b4568b435556bf4774245'] | I have a table with the following rows:
and I am trying to do a weighted average by Product and ReceiptYearMonth of CaseQuantity
I have created the following DAX measure to try to create the weighted average:
SumX Test = sumx(Query1,
Query1[CaseQuantity] /
calculate(
sum(Query1[Case... | 3392b8b8add86a1581bce1c81a70ef2b699153072d231bf39706cb91bd7800dc | ['cb0d4714f92b4568b435556bf4774245'] | You could try using the OFFSET x ROWS FETCH NEXT y ROWS ONLY commands like this:
CREATE TABLE TempTable (
TempID INT IDENTITY(1,1) NOT NULL,
SomeDescription VARCHAR(255) NOT NULL,
PRIMARY KEY(TempID))
INSERT INTO TempTable (SomeDescription)
VALUES ('Description 1'),
('Description 2'),
('Descriptio... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.