text stringlengths 485 43.7k | meta dict |
|---|---|
Q:
Visualising factors
I've come across a problem that asks me to print a table to visualize all factors of each integer ranging from 1 to limit. Then it specifies that a given position i, starting from 1 in a row n, then a * indicates that i is a factor of n, and - indicates that it is not. Below is an example of t... | {
"pile_set_name": "StackExchange"
} |
Q:
Unable to parse a value inside json object in javascript
I am trying to parse a value which is residing inside a json object . Below is the response from my API call.
var responseData = {
"statusCode": 200,
"body": "{\"Errors\":\"\",\"Message\":null,\"OrgID\":0,\"Output\":\"{\\\"AllUserDetails\\\":{\\\"UserDet... | {
"pile_set_name": "StackExchange"
} |
Q:
Lingo letters not working sometimes
I have to create a Lingo (*) game as an assignment for my school.
I finally finished it, but sometimes the letter bug and don't get a color or the wrong color.
var words = ["appel", "aldus", "afwas", "aftel", "aarde", "armen", "actie", "apart", "adres", "avond", "aders", "alarm... | {
"pile_set_name": "StackExchange"
} |
Q:
ASP.NET MVC2 CrAzY Characters in View Output - WTF
Every once in a while when I'm running my app I get really "REALLY" strange characters in my output instead of the appropriate page. Now I know that this is because of some error, but unfortunately the error doesn't present it's self, but rather just produces str... | {
"pile_set_name": "StackExchange"
} |
Q:
Pattern quote creates excessive amount of \Q and \E
While replacing the string X with any pattern from ArrayList S, the new message N, produces an excessive amount of regex quotes, \Q and \E.
Is their some kind of way to break the loop once it reads through the message or implement some kind of count down to preve... | {
"pile_set_name": "StackExchange"
} |
Q:
Regex Extract [Jmeter]
To make this short: I have a json response, and I need to extract some parameters from it. (Using jmeter, Regular Expression Extractor)
json response:
{"success":true,"data":[{"valId":null,"oclOclIdIndexType":null,"yearno":null,"docId":274253,"iconCls":null,"versionNo":1,"parentId":null,"id... | {
"pile_set_name": "StackExchange"
} |
Q:
find All Combinations of 0's and 1's with specific number of 1's
I want to find a matrix with all possible combinations of 0's and 1's. The conditions of these possible combinations are no reputation of individual possibilities, and for each possible vector has the specified number of 1's. For example, I have a nu... | {
"pile_set_name": "StackExchange"
} |
Q:
find All Combinations of 0's and 1's with specific number of 1's
I want to find a matrix with all possible combinations of 0's and 1's. The conditions of these possible combinations are no reputation of individual possibilities, and for each possible vector has the specified number of 1's. For example, I have a nu... | {
"pile_set_name": "StackExchange"
} |
Q:
Is the domination number of a combinatorial design determined by the design parameters?
Let $D$ be a $(v,k,\lambda)$-design. By the domination number of $D$ I mean the domination number $\gamma(L(D))$ of the bipartite incidence graph of $D$.
Is $\gamma(L(D))$ determined only by $v,k$, and $\lambda$,
irrespectiv... | {
"pile_set_name": "StackExchange"
} |
Q:
url param not getting properly
I have a two server.I am passing 4 variable in url ssid(36),rawstring(1024),sample_id,user_id.
I simplely want to get parameter passed in url.When I hit my first server I am getting param,but same url(Only change server name),I get 3 parameters(not getting raw string).
In my controll... | {
"pile_set_name": "StackExchange"
} |
Q:
How can I merge several hashes into one hash in Perl?
In Perl, how do I get this:
$VAR1 = { '999' => { '998' => [ '908', '906', '0', '998', '907' ] } };
$VAR1 = { '999' => { '991' => [ '913', '920', '918', '998', '916', '919', '917', '915', '912', '914' ] } };
$VAR1 = { '999' => { '996' => [] } };
$VAR1 = { '99... | {
"pile_set_name": "StackExchange"
} |
Q:
JsonConvert.serializeObject with dataset returning unexpected result
I am trying to convert dataset to JSON in .net core 2.0 and am using the below code to do that
return Ok(JsonConvert.SerializeObject(dataset, Formatting.Indented))
and the output I am getting is
"{\n \"DataSet.RemotingVersion\": {\n \"Major\"... | {
"pile_set_name": "StackExchange"
} |
Q:
Grey scale plot matrix in GGally
I want to create a plot matrix using GGally in greyscale. I have tried with functions like scale_colour_grey but GGally only recognises theme objects from ggplot2. Reproducible data and code are provided below:
Cluster = c(1, 2, 1, 3, 1, 1, 1, 1, 1, 2, 2, 3, 4, 4, 1, 4, 1, 1, 2, 1,... | {
"pile_set_name": "StackExchange"
} |
Q:
Is it possible or how to extract message string from binarized list?
Given message copied from Silvia's profile page, a binarized list could be found bellow.
lst = Uncompress@
"1:eJztk8ENwzAIRUkHyA5ZqdfeMkC6/605Vl8Gg8EykUD6imMb8/hxjvP7vl5EtN/\
63NpKpVIpqSgBg4XzKbwzvP6PJ/Baa2BvxMxzea1caV2al3zQnId7pHqS1yPsEkPPa8/... | {
"pile_set_name": "StackExchange"
} |
Q:
How to clone array of hashes and add key value using each loop
I want to clone an array of hashes and then to clone it into more than one.
irb(main):001:0> arr = [{a: "one", b: "two"}, {a: "uno", b: "due"}, {a: "en", b: "to"}]
=> [{:a=>"one", :b=>"two"}, {:a=>"uno", :b=>"due"}, {:a=>"en", :b=>"to"}]
irb(main):002... | {
"pile_set_name": "StackExchange"
} |
Q:
External Dependency Using cloud foundry CLI not working
I am trying to write a script to create external dependency service on cloud foundry, the script executes successfully but it not displaying IPs on web panel. Even when i bind the service with app it not allowing the listed IPs also. But if i configure extern... | {
"pile_set_name": "StackExchange"
} |
Q:
Summarise grouping by varname
I'm analysing some data, and I've come a difficulty - I don't know how to summarise my whole dataset using the variable names as the "group".
A sample data:
structure(list(x4 = c(3, 4, 7, 4, 5, 1, 5, 2, 7, 1), x5 = c(2,
4, 4, 4, 5, 3, 6, 1, 7, 1), x6 = c(3, 5, 4, 7, 5, 4, 6, 4, 6,
2... | {
"pile_set_name": "StackExchange"
} |
Q:
Ruby on Rails Saving to Database
Hi i'm a beginner in Ruby on Rails
Here is my doubt.
I have this method in my controller
def save_profile
p "======================================"
p params
p "======================================"
p params[:company][:job_locations_attributes]
p "company_para... | {
"pile_set_name": "StackExchange"
} |
Q:
MVC Bundle fails to load
We're having a strange problem that we can't seem to find a cause for. What seems to happen is the javascript and css bundles no longer load on the page.
When we initially navigate to the page everything seems to be working fine. After two page refreshes the page loads without any css and... | {
"pile_set_name": "StackExchange"
} |
Q:
Maintain order of time series with group_by
Suppose my time series consists only of two columns: signal and day
The signal variable is supposed to repeat itself in a cycle of 1 to 6. So I need to insert empty rows for each implicit missing Signal but with signal counting from 1 to 6. (Suppose I have more columns t... | {
"pile_set_name": "StackExchange"
} |
Q:
How to get random number list, with fixed sum and size
How to get random number list by give size, and expectd sum, fully support
i hava a code sum-int.ts sum-float.ts internal/sum-num.ts
whai i want to do
rN = radom number ( float or int ) between min ~ max
size = [r1, r2, r3, ...rN].length
sum = r1 + r2 + r3 + ... | {
"pile_set_name": "StackExchange"
} |
Q:
How to efficiently apply an operator to the cartesian product of two arrays?
I have a = array([1, 2, 3, 4, 5]) and b = array([10, 20, 30, 40, 50]). I want:
array([[ -9, -19, -29, -39, -49],
[ -8, -18, -28, -38, -48],
[ -7, -17, -27, -37, -47],
[ -6, -16, -26, -36, -46],
[ -5, -15, -25, ... | {
"pile_set_name": "StackExchange"
} |
Q:
Decrypt base64 ciphertext with nodejs
I have this ciphertext:
7GfBCT3ZLyS+yZ3gmyMi6zPneB7Chuu7gitxlZbPlA47Y2hpKPhfxqkW8pr7Jygv/ew7Oqk+YG9fn+yCh6KcrKb+1UfdrdLNr1FdFxbQvhFVr76My1Mm4NYDE+a8q/FCIiTjPvukGhxlR6qiS5qfg9bl3IwpJJfetSemqLNGNSQw6LJXP15HvfZUjmuV3ezsvwsX2fOsdUbvgHI22Owp85tC8KVq79RAA58wHardPRSr4I1kjsF8kDg0jSJef... | {
"pile_set_name": "StackExchange"
} |
Q:
Magic Square Mixups [Challenge]
This kind of puzzle is different than your normal magic square puzzles. Here are 3, in increasing difficulty. Some numbers have been switched, and you have to find them and swap them around to make the magic square valid again.
The zeros are for formatting placeholders.
The numbers... | {
"pile_set_name": "StackExchange"
} |
Q:
Simulate correlated variables limiting deviations between observed and defined correlation coefficients
dev_allowance <- 0.15 #Deviation in r allowed
within_limit <- FALSE #Initiate
count <- 0 #Loop count
nvar <- 10 #number of variables to simulate
nobs = 50 #n... | {
"pile_set_name": "StackExchange"
} |
Q:
How do I print a grid from a list of lists with numbered rows and columns
I'm trying to create a grid that's n_rows by n_columns, which will be changeable. This is my code; it takes a list of lists and the two dimension integers:
def _print_board(game_state: list, n_rows: int, n_columns: int)-> None:
for i in ... | {
"pile_set_name": "StackExchange"
} |
Q:
What is this method of display images called?
On Google Images, some images are loaded like this:
data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBhQSEBQUEhQVFRQWFBQXFRYVFRQQFhIUFBQXFRYWFxQYHCYfGBkjGRcUHy8gIycpLCwsFR4xNTAqNSYrLCkBCQoKDgwOGg8PGi8kHyQyLCwsLCwtLiwsLC0sKSwsLCwsKSwsLCosLCwpLCwsLCksLCwsLCwsLC... | {
"pile_set_name": "StackExchange"
} |
Q:
Smooth interpolating spline has weird extremities
I'm building a soft to reject some trajectories that turn too fast.
I managed to smooth them with scipy splrep and splev, but I have some weirdness at the beginning and the end, with some points that does not follow at all the original trajectory.
Any idea where it... | {
"pile_set_name": "StackExchange"
} |
Q:
Awk pattern matching
I want to print
userId = 1234
userid = 12345
timestamp = 88888888
js = abc
from my data
messssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss
<input name="userId" value="1234" type="hidden"> messsssssssssssssssssss
<input name="userid" value="12345" type="hidden"> messsssss... | {
"pile_set_name": "StackExchange"
} |
Q:
Parse Python's serialized object in Perl
I need to make my Perl code read some Python's serialized object for later processing. I came with parser based on Parse::MGC, but it's slow. May be I did it wrong or may be someone knows better way to convert Python's serialized object in some sort of Perl structure?
Here ... | {
"pile_set_name": "StackExchange"
} |
Q:
Matlab, get the peaks in a vector, this does not work: max_locations = find(A==max(A))
In Matlab, I have the following matrix:
A = [0,0,0,0,0,0,0,0,0,0,8,32,52,36,12,0,1,2,0,0,0,0,0,0,0,0,0,1,2,1,163,60,
21,31,34,35,38,38,40,38,38,40,34,37,39,34,32,32,33,31,39,40,37,36,24,39,162,
23,23,22,22,29,25,23,24,25,24,24,2... | {
"pile_set_name": "StackExchange"
} |
Q:
Generators of $O_8^+(2):\mathbb Z_2$
I am trying to find out what the generators of $O_8^+(2):\mathbb Z_2$ are, and they are given in the ATLAS of Finite Group Representations. However I do not understand the explanation given:
Standard generators of O8+(2):2 are c, d where c is in class 2F, d is in class 10BC an... | {
"pile_set_name": "StackExchange"
} |
Q:
Unexpected JSON output on HTTP request
I am currently trying to get a simple HTTP JSON response from a website.
When I look at the page when I use Google Chrome:
{"columns":[{"name":"xx","dataType":"varchar","size":255,"nullable":true},{"name":"xx","dataType":"varchar","size":255,"nullable":true},{"name":"xx","dat... | {
"pile_set_name": "StackExchange"
} |
Q:
Dumb7Fill queen and rook attacks seem to jump over "ours" pieces
I am trying to play with chess programming and currently program BitBoards. All is fine except for Dumb7Fill (unrolled loops) generating attacks that allow queen and rook jump over their pieces. Bellow are traces of execution. What am I doing wrong h... | {
"pile_set_name": "StackExchange"
} |
Q:
Raise MultiValueDictKeyError by request.FILES to get base64 image data
Actually i need to get base64 image data generated by croppie javascript library. The image data look like below.
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAgAElEQVR4Xs1dB5xU1dX/39em7c422GXpVZGmWACxImAviYnYY/1UjLF8iYkx... | {
"pile_set_name": "StackExchange"
} |
Q:
Text files manipulating in Linux
I have a bunch of CSV files in a folder (OS: Ubuntu). All of them on the same structure. more than 2k columns (That's how of got it). The first column is ID.
I'm not able to work with SQL (nevermind why), so i guess i will need to work with bash command such as awk, cut, sed, etc w... | {
"pile_set_name": "StackExchange"
} |
Q:
Individual shift of each column in a matrix
I look for a R-code that transform the matrix as follows (a: the original matrix, b: the desired output), example:
a <- matrix(c(1,2,3,4,5,6,1,2,3,4,5,6,1,2,3,4,5,6,1,2,3,4,5,6), nrow = 6, ncol = 4)
b <- matrix(c(1,2,3,4,5,6,2,3,4,5,6,0,3,4,5,6,0,0,4,5,6,0,0,0), nro... | {
"pile_set_name": "StackExchange"
} |
Q:
find a condition on B,C so set difference is associative (A\B)\C=A\(B\C)
Im trying to find a some conditions on the sets $B,C$ so the following will be correct:
for all $A$, $(A\setminus B)\setminus C= A\setminus (B\setminus C)$ if and only if ** condition **
(set theory)
A:
Break things into logical statemen... | {
"pile_set_name": "StackExchange"
} |
Q:
OpenCV-OpenGL interoperability
I'm under Linux and compiled OpenCV 2.4.4 with OpenGL support, but I don't have any idea of how using the opengl_interop.hpp functions (some of them are even undocumented!, at least on my version of documentation). Looking at window.cpp in the section with OpenGL enabled I found some... | {
"pile_set_name": "StackExchange"
} |
Q:
How to evaluate $\int \frac{x dx}{x^4 + 6x^2 + 5}$?
$$\int \frac{x dx}{x^4 + 6x^2 + 5}$$
How to evaluate this integral ?
A:
$$\int \frac { xdx }{ x^{ 4 }+6x^{ 2 }+5 } =\frac { 1 }{ 2 } \int { \frac { d{ x }^{ 2 } }{ { \left( { x }^{ 2 }+3 \right) }^{ 2 }-4 } } =\frac { 1 }{ 2 } \left[ \int { \frac { d{ x }^{ ... | {
"pile_set_name": "StackExchange"
} |
Q:
How to create a new dictionary, that has the values of one dictionary as keys and the values of another dictionary as values
I have two dictionaries. In reality they are much longer.
First:
Data = { "AT" : [1,2,3,4], "BE" : [ 4,2,1,6], "DE" : [ 5,7,8,9] }
2nd dict:
Data2 = { "AT" : ["AT1","AT2","AT3"], "BE" : ["B... | {
"pile_set_name": "StackExchange"
} |
Q:
Is it possible to assign an object while destructuring another (WHILE using defaults in destructuring)
My end goal is to be able to assign a new object using the spread operator from an object that is destructured while assigning default values (if they don't exist).
It looks like this may not be possible how I'd ... | {
"pile_set_name": "StackExchange"
} |
Q:
Rails: sending an array of hashes from form to server
In my parameters hash, I am trying to achieve something like the following:
{"utf8"=>"✓", "authenticity_token"=>"6A14fVUEWQSB83j2BsYKn", "search"=>{"keywords"=>[{"keyword_names"=>"color", "keyword_conditions"=>"is not", "keyword_values"=>"red"}, {"keyword_names... | {
"pile_set_name": "StackExchange"
} |
Q:
Gallery fo bcms 3.3.3 error - ruby on rails
heeey!)
I was trying to make a gallery but i get an error on file upload
model gallery.rb
class Gallery < ActiveRecord::Base
acts_as_content_block
has_attached_file :avatar, :styles => { :thumb => "291x191#" }
#attr_accessible :images
has_many :images
accept... | {
"pile_set_name": "StackExchange"
} |
Q:
Remove multiple elements from a List
Im having a problem with this python code:
card_list = ["1P", "1C", "1O","1E", "2P", "2C", "2O", "2E", "3P", "3C", "3O",
"3E", "4P", "4C", "4O", "4E", "5P", "5C", "5O", "5E", "6P", "6C", "6O",
"6E", "7P", "7C", "7O", "7E", "8P", "8C", "8O", "8E", "9P", "9C", "9O", "... | {
"pile_set_name": "StackExchange"
} |
End of preview. Expand in Data Studio
README.md exists but content is empty.
- Downloads last month
- 3