qid int64 4 19.1M | question stringlengths 18 48.3k | answers list | date stringlengths 10 10 | metadata list |
|---|---|---|---|---|
74,375,556 | <p>My tables</p>
<ol>
<li>users</li>
</ol>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>id</th>
<th>name</th>
</tr>
</thead>
<tbody>
<tr>
<td>Cell 1</td>
<td>Cell 2</td>
</tr>
<tr>
<td>Cell 3</td>
<td>Cell 4</td>
</tr>
</tbody>
</table>
</div>
<ol start="2">
<li>group</li>
</ol>
<div class="... | [
{
"answer_id": 74375600,
"author": "Techno",
"author_id": 2595985,
"author_profile": "https://Stackoverflow.com/users/2595985",
"pm_score": 1,
"selected": false,
"text": "$users = User\n ::whereDoesntHave('groups', fn($query) => $query->where('id', 1))\n ->get();\n"
},
{
"a... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375556",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12625165/"
] |
74,375,562 | <h2>Scenario:</h2>
<p>Invoice has many purchase_orders and purchase_orders has many invoices. Intermediate table is npayment_links which has foreign key invoice_id, purchase_order_id.</p>
<h2>Tech Stack</h2>
<p>Rails 5.x,
Postgresql</p>
<p>Here is my sample data</p>
<h2>invoices</h2>
<div class="s-table-container">
<ta... | [
{
"answer_id": 74375600,
"author": "Techno",
"author_id": 2595985,
"author_profile": "https://Stackoverflow.com/users/2595985",
"pm_score": 1,
"selected": false,
"text": "$users = User\n ::whereDoesntHave('groups', fn($query) => $query->where('id', 1))\n ->get();\n"
},
{
"a... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375562",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2606967/"
] |
74,375,568 | <p><a href="https://i.stack.imgur.com/i0gPn.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/i0gPn.png" alt="enter image description here" /></a>I Have a list containing some ids, I have to call an api with each of ids in the list and store all the data that comes from the api in a list,I am mapping t... | [
{
"answer_id": 74375791,
"author": "Naveen",
"author_id": 16260451,
"author_profile": "https://Stackoverflow.com/users/16260451",
"pm_score": 1,
"selected": false,
"text": "const[deviceList, setDeviceList] = useState([]);\n useEffect(()=>{\n const datafetch=async()=>{\n deviceidlist... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375568",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20288092/"
] |
74,375,607 | <p>I need to get the value of an environment variable from a kubernetes pod. I have my values listed in a hash table.</p>
<p>I call
<code>$hash["service-testurl"].spec.template.spec.containers.env</code>
And it returns a table:</p>
<pre><code>name value
---- ... | [
{
"answer_id": 74377435,
"author": "wolfdebs",
"author_id": 11119465,
"author_profile": "https://Stackoverflow.com/users/11119465",
"pm_score": 1,
"selected": false,
"text": "$hash[\"service-testurl\"].spec.template.spec.containers.env.where{$_.name -eq 'ADDR'}.value\n"
},
{
"ans... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375607",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11119465/"
] |
74,375,608 | <p>im having this byte class</p>
<pre><code>b'ToCountry=US&ToState=WA&SmsMessageSid=SM2c04173b9a5f684be8019e177978c791&NumMedia=0&ToCity=&FromZip=&SmsSid=SM2c04173b9a5f684be8019e177978c791&FromState=&SmsStatus=received&FromCity=&Body=Bbjhggggggg&FromCountry=EE&To=%2B15095... | [
{
"answer_id": 74375668,
"author": "ikibir",
"author_id": 12194720,
"author_profile": "https://Stackoverflow.com/users/12194720",
"pm_score": 2,
"selected": false,
"text": "a = b'ToCountry=US&ToState=WA&SmsMessageSid=SM2c04173b9a5f684be8019e177978c791&NumMedia=0&ToCity=&FromZip=&SmsSid=S... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375608",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3073987/"
] |
74,375,611 | <p><strong>Scenario:</strong>
The API basically calls an endpoint to get the token and then sets the token in the header and calls another endpoint along with other query parameters.</p>
<p><strong>Problem:</strong>
I'm getting the null resolving to address issue.</p>
<pre><code>[2022-11-09 18:08:19,327] INFO {LogMedi... | [
{
"answer_id": 74376084,
"author": "ycr",
"author_id": 2627018,
"author_profile": "https://Stackoverflow.com/users/2627018",
"pm_score": 0,
"selected": false,
"text": "pep-scan / uri-template=\"https://msaaspro.com/api/v1/scan/pep-scan?fullname={uri.var.name}&searchtype=fuzzy&fat... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375611",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7454536/"
] |
74,375,620 | <p>I know there are <em>many</em> questions about <code>this</code>, and I have read many answers and references, including <a href="https://stackoverflow.com/a/20279485/1925272">this canonical answer</a>. However, I am not able to derive a solution to my specific problem.</p>
<p>Here is a sample code:</p>
<p><div clas... | [
{
"answer_id": 74375761,
"author": "StephenHawking",
"author_id": 13988248,
"author_profile": "https://Stackoverflow.com/users/13988248",
"pm_score": 0,
"selected": false,
"text": "class A {\n\n constructor(myField) {\n this.myField = myField;\n }\n\n myMethod(instance) {\n cons... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375620",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1925272/"
] |
74,375,621 | <p>How to convert <code>List<string></code> to <code>List<object></code> property in c#</p>
<p>We have a list of email id's</p>
<pre><code>List<string> str= new List<string>{"abc1@gmail.com","abc2@gmail.com"};
</code></pre>
<p>and now we have to assign these email IDs to the ... | [
{
"answer_id": 74375622,
"author": "Samadhan",
"author_id": 5521340,
"author_profile": "https://Stackoverflow.com/users/5521340",
"pm_score": 0,
"selected": false,
"text": "List<string> List<object> //here Employee is an Object type\npublic static void Main(string[] args)\n {\n ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375621",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5521340/"
] |
74,375,624 | <p>I am currently trying to get the Size and reshape my rectangle to the actual size of the image (width and height). However when i use Image.Height or Image.Width its always 0. The picture that is displayed when i start the program takes up the entire screen</p>
<pre><code> Uri imageUri = new Uri(FileListe... | [
{
"answer_id": 74375622,
"author": "Samadhan",
"author_id": 5521340,
"author_profile": "https://Stackoverflow.com/users/5521340",
"pm_score": 0,
"selected": false,
"text": "List<string> List<object> //here Employee is an Object type\npublic static void Main(string[] args)\n {\n ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375624",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20450256/"
] |
74,375,659 | <p>Considering this code:</p>
<pre><code>var x = 3;
var i = 0;
while (i < 3) {
x += 1;
i += 1;
}
println(x);
</code></pre>
<p>Why would the output be 6? Can someone break it down for me?</p>
<p>I understand that x will continue adding 1 to it's value, but why does the i<3 limit it to 6?</p>
| [
{
"answer_id": 74375710,
"author": "arthur",
"author_id": 1275802,
"author_profile": "https://Stackoverflow.com/users/1275802",
"pm_score": 1,
"selected": false,
"text": "i = 0 => x +1 = 4\ni = 1 => x + 1 = 5\ni = 2 => x + 1 = 6\ni = 3 => exit loop\n"
},
{
"answer_id": 74377098,
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375659",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19944757/"
] |
74,375,662 | <pre><code>print(n1)
print(n2)
print(type(n1), type(n2))
print(scipy.stats.spearmanr(n1, n2))
print(n1.corr(n2, method="spearman"))
0 2317.0
1 2293.0
2 1190.0
3 972.0
4 1391.0
Name: r6000, dtype: float64
0.0 2317.0
1.0 2293.0
3.0 1190.0
4.0 972.0
5.0 1391.0
Name: 6000, dtype: f... | [
{
"answer_id": 74375710,
"author": "arthur",
"author_id": 1275802,
"author_profile": "https://Stackoverflow.com/users/1275802",
"pm_score": 1,
"selected": false,
"text": "i = 0 => x +1 = 4\ni = 1 => x + 1 = 5\ni = 2 => x + 1 = 6\ni = 3 => exit loop\n"
},
{
"answer_id": 74377098,
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375662",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/538524/"
] |
74,375,664 | <pre><code></code></pre>
<pre><code>vector<vector<int>> floodFill(vector<vector<int>>& image, int sr, int sc, int color) {
int prevColor = image[sr][sc];
int m = image.size();
int n = image[0].size();
image[sr][sc] = color;
stack <pair<int, int>> positionT... | [
{
"answer_id": 74376352,
"author": "jwezorek",
"author_id": 1413244,
"author_profile": "https://Stackoverflow.com/users/1413244",
"pm_score": 1,
"selected": false,
"text": "if (sr<n-1 && image[sr][sc+1] == prevColor )\n if (sc<n-1 && image[sr][sc+1] == prevColor )\n"
},
{
"answer... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12315498/"
] |
74,375,681 | <p>I'm fairly new to React. I am working on a note app and when I add 2 notes, they have the same key and the next 2 notes also share their own key and so on. I started off with prop drilling from the App to the AddNote file via NotesList.js and it was working fine and the problem has only occurred since I used useCo... | [
{
"answer_id": 74376352,
"author": "jwezorek",
"author_id": 1413244,
"author_profile": "https://Stackoverflow.com/users/1413244",
"pm_score": 1,
"selected": false,
"text": "if (sr<n-1 && image[sr][sc+1] == prevColor )\n if (sc<n-1 && image[sr][sc+1] == prevColor )\n"
},
{
"answer... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375681",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20396703/"
] |
74,375,683 | <p>im trying to learn how to reverse a number but came across a problem about this Do-While loop. Specifically
<code>while (n1)</code>. Usually i just see people put in a condition with about comparison.</p>
<pre><code>#include <iostream>
#include <conio.h>
using std::cout;
using std::cin;
using std::endl;
... | [
{
"answer_id": 74376352,
"author": "jwezorek",
"author_id": 1413244,
"author_profile": "https://Stackoverflow.com/users/1413244",
"pm_score": 1,
"selected": false,
"text": "if (sr<n-1 && image[sr][sc+1] == prevColor )\n if (sc<n-1 && image[sr][sc+1] == prevColor )\n"
},
{
"answer... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375683",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18519699/"
] |
74,375,686 | <p>There is <code>ParentFragment</code> that shows <code>DialogFragment</code>. I <code>collect</code> a dialog result through <code>SharedFlow</code>. When result received, dialog dismissed. Should I stop <code>collect</code> by additional code? What happens when dialog closed, but fragment still resumed?</p>
<pre><co... | [
{
"answer_id": 74376352,
"author": "jwezorek",
"author_id": 1413244,
"author_profile": "https://Stackoverflow.com/users/1413244",
"pm_score": 1,
"selected": false,
"text": "if (sr<n-1 && image[sr][sc+1] == prevColor )\n if (sc<n-1 && image[sr][sc+1] == prevColor )\n"
},
{
"answer... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375686",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5894542/"
] |
74,375,694 | <p>Are these 2 situations in Constraint Layout equivalent?</p>
<p><strong>First situation:</strong></p>
<p><em>Attributes of element 1:</em></p>
<pre><code> android:id="@+id/view1"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
</code>... | [
{
"answer_id": 74376352,
"author": "jwezorek",
"author_id": 1413244,
"author_profile": "https://Stackoverflow.com/users/1413244",
"pm_score": 1,
"selected": false,
"text": "if (sr<n-1 && image[sr][sc+1] == prevColor )\n if (sc<n-1 && image[sr][sc+1] == prevColor )\n"
},
{
"answer... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375694",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20018861/"
] |
74,375,708 | <p>I want to remove specific or full parameters from the URL of the website when it is actively loading in the browser. I want to do this because some website including additional strings.</p>
<pre><code>https://www.example.com/?gclid=anything
https://www.example.com/?fbclid=anything
https://www.example.com/?msclid=any... | [
{
"answer_id": 74375867,
"author": "dvicemuse",
"author_id": 1155184,
"author_profile": "https://Stackoverflow.com/users/1155184",
"pm_score": 2,
"selected": true,
"text": "https://www.example.com/?fbclid=something https://www.example.com/ window.history.pushState({}, '', '/');\n"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375708",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19897682/"
] |
74,375,721 | <p>I want to check if child component is mounted and I want to move that information to he parent component. For this I am using emits.
So with example here is my parent component:</p>
<pre><code><child @is-child-mounted="childMounted" />
export default {
data() {
return {
childMounted: fal... | [
{
"answer_id": 74375867,
"author": "dvicemuse",
"author_id": 1155184,
"author_profile": "https://Stackoverflow.com/users/1155184",
"pm_score": 2,
"selected": true,
"text": "https://www.example.com/?fbclid=something https://www.example.com/ window.history.pushState({}, '', '/');\n"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375721",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19850691/"
] |
74,375,739 | <p><strong>I was using <a href="https://pub.dev/packages/sn_progress_dialog/install" rel="nofollow noreferrer">sn_progress_dialog</a> when I ran into the error that the asset for this dependency is not found..</strong></p>
<p>However, the official documentation does not mention anything about setting assets for this de... | [
{
"answer_id": 74375867,
"author": "dvicemuse",
"author_id": 1155184,
"author_profile": "https://Stackoverflow.com/users/1155184",
"pm_score": 2,
"selected": true,
"text": "https://www.example.com/?fbclid=something https://www.example.com/ window.history.pushState({}, '', '/');\n"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375739",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12898752/"
] |
74,375,746 | <p>I want to convert a VARCHAR2-value like '-28:15:00' to INTERVAL.</p>
<p>With a literal value, this works:</p>
<pre><code>select interval '-09:11:36' hour to second from dual;
</code></pre>
<p>However, this does not (ORA-00923: FROM keyword not found where expected):</p>
<pre><code>select interval MY_VARCHAR hour to ... | [
{
"answer_id": 74375867,
"author": "dvicemuse",
"author_id": 1155184,
"author_profile": "https://Stackoverflow.com/users/1155184",
"pm_score": 2,
"selected": true,
"text": "https://www.example.com/?fbclid=something https://www.example.com/ window.history.pushState({}, '', '/');\n"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375746",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1206791/"
] |
74,375,747 | <p>How can I turn each element in a numpy array into its index in another array?</p>
<p>Take the following example. Let <code>a = np.array(["a", "c", "b", "c", "a", "a"])</code> and <code>b = np.array(["b", "c", "a"])</code>. How ... | [
{
"answer_id": 74375913,
"author": "Bharat Adhikari",
"author_id": 17731030,
"author_profile": "https://Stackoverflow.com/users/17731030",
"pm_score": 2,
"selected": false,
"text": "import numpy as np\na = np.array([\"a\", \"c\", \"b\", \"c\", \"a\", \"a\"])\n\nb = np.array([\"b\", \"c\"... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375747",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5308892/"
] |
74,375,751 | <p>I would like to create a <code>const std::vector</code> to contain all the elements of two other <code>const std::vector</code> of the same type. Since the vector is <code>const</code> I can not concatenate it step by step with the two <code>const std::vector</code> using the method mentioned in <a href="https://sta... | [
{
"answer_id": 74375849,
"author": "Ayxan Haqverdili",
"author_id": 10147399,
"author_profile": "https://Stackoverflow.com/users/10147399",
"pm_score": 4,
"selected": true,
"text": "const std::vector<int> int_a{0,1};\nconst std::vector<int> int_b{2,3};\nconst std::vector<int> all_ints = ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375751",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12828370/"
] |
74,375,757 | <p>I have a list of lists of strings (Essentially it's a corpus) and I'd like to convert it to a matrix where a row is a document in the corpus and the columns are the corpus' vocabulary.</p>
<p>I can do this with <code>CountVectorizer</code> but it would require quite a lot of memory as I would need to convert each li... | [
{
"answer_id": 74376135,
"author": "mozway",
"author_id": 16343464,
"author_profile": "https://Stackoverflow.com/users/16343464",
"pm_score": 3,
"selected": true,
"text": "collections.Counter DataFrame from collections import Counter\n\ncorpus = [['a', 'b', 'c'],['a', 'a'],['b', 'c', 'c'... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375757",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19239577/"
] |
74,375,768 | <p>In my Xamarin Forms project I have:</p>
<pre><code>[BroadcastReceiver(Permission = "RECEIVE_BOOT_COMPLETED",
Exported = true,
Enabled = true)]
[IntentFilter(new[] {Intent.ActionBootCompleted})]
public class GeofenceReceiver: BroadcastReceiver
</code></pre>
<p>I use it for GeofenceTransitionEnter an... | [
{
"answer_id": 74376135,
"author": "mozway",
"author_id": 16343464,
"author_profile": "https://Stackoverflow.com/users/16343464",
"pm_score": 3,
"selected": true,
"text": "collections.Counter DataFrame from collections import Counter\n\ncorpus = [['a', 'b', 'c'],['a', 'a'],['b', 'c', 'c'... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375768",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16059485/"
] |
74,375,778 | <p>I am obtaining undesired results in python.</p>
<p>Goal: I want to assign the constant value to the respective element of the 2D matrix.
I have indey list of the row and colum</p>
<pre><code>idx_container_phi = [22, 19, 25, 23, 22, 21, 22, 30, 16, 12, 14] # row index
idx_container_theta = [22, 19, 10, 23, 22, 7, 22,... | [
{
"answer_id": 74376219,
"author": "Rabinzel",
"author_id": 15521392,
"author_profile": "https://Stackoverflow.com/users/15521392",
"pm_score": 2,
"selected": true,
"text": "idx_container_phi = [1, 7, 3, 4, 1] # row index\nidx_container_theta = [3, 5, 2, 4, 3] # column index\nthickness =... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375778",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17289097/"
] |
74,375,816 | <p>I am trying to remove redundant rows in my parametrized tests. Redundant - I mean I repeat this kind of code all the time.</p>
<p>Here is example of my test:</p>
<pre><code>1 @pytest.mark.parametrize("field, violations", [
2 (None, [NULL_VIOLATION]),
3 (True, []),
4 (False, [])
5 ])
6 def... | [
{
"answer_id": 74380691,
"author": "picobit",
"author_id": 6030926,
"author_profile": "https://Stackoverflow.com/users/6030926",
"pm_score": 0,
"selected": false,
"text": "pytest_generate_tests import pytest\n\n@pytest.mark.parametrize(\n \"a, b\",[(1,10),(2,20)]\n)\ndef test_param_fu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375816",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20212721/"
] |
74,375,887 | <p>I am new to python, may i know</p>
<p>Define a procedure that finds the index of the second instance of a string in a larger string.</p>
<pre><code>def find_second(findin, whattofind):
return
find_second('dance, dance, dance everyday', 'dance')
find_second('learning about data, surprisingly, requires a lot o... | [
{
"answer_id": 74380691,
"author": "picobit",
"author_id": 6030926,
"author_profile": "https://Stackoverflow.com/users/6030926",
"pm_score": 0,
"selected": false,
"text": "pytest_generate_tests import pytest\n\n@pytest.mark.parametrize(\n \"a, b\",[(1,10),(2,20)]\n)\ndef test_param_fu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375887",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459673/"
] |
74,375,922 | <p>Lets say we have a 12 tasks, we need to runn all of them with one condition: we can have only 3 tasks running simultaneously. So we can start only 3 tasks at the beggining, then wayt until one of them finishes and launch another one. I am using Asyncio with semafore for this purpose in the simple code below.</p>
<pr... | [
{
"answer_id": 74380691,
"author": "picobit",
"author_id": 6030926,
"author_profile": "https://Stackoverflow.com/users/6030926",
"pm_score": 0,
"selected": false,
"text": "pytest_generate_tests import pytest\n\n@pytest.mark.parametrize(\n \"a, b\",[(1,10),(2,20)]\n)\ndef test_param_fu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375922",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20426821/"
] |
74,375,976 | <p>im trying to make a search box with a magnifying glass icon that becomes blue when the input field is focused.</p>
<p>the MagnifyingGlass component inherits its color from its parent element.</p>
<pre><code>import styles from './Search.module.sass';
import { useState } from 'react';
import MagnifyingGlass from '../.... | [
{
"answer_id": 74376058,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 0,
"selected": false,
"text": "const Search = () => {\n \n\n const [inputValue, setInputValue] = useState('');\n \n const [show, toggl... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74375976",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20061501/"
] |
74,376,018 | <p>I am writing this code for simulation of earths magnetic field:</p>
<pre><code>import numpy as np
import matplotlib.pyplot as plt
import magpylib as magpy
import pyvista as pv
ts = np.linspace(-8,8, 150)
t = np.linspace(-6,6, 150)
axis = np.c_[2*np.cos(ts*2*np.pi), 2*np.sin(ts*2*np.pi), ts]
aux = np.c_[2*np.cos(ts*... | [
{
"answer_id": 74376058,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 0,
"selected": false,
"text": "const Search = () => {\n \n\n const [inputValue, setInputValue] = useState('');\n \n const [show, toggl... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376018",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20275232/"
] |
74,376,039 | <p>My problem looks like this:</p>
<pre><code>data_example <-
c("Creditshelf Aktiengesellschaft / Key word(s): Forecast/Development of Sales\n\ncreditshelf Aktiengesellschaft",
"Swiss Life Holding AG / Key word(s): 9 Month figures\n\nSwiss Life increases fee income by 13%",
"tonies... | [
{
"answer_id": 74376131,
"author": "Wiktor Stribiżew",
"author_id": 3832970,
"author_profile": "https://Stackoverflow.com/users/3832970",
"pm_score": 2,
"selected": false,
"text": "str_extract(data, \"Key word\\\\(s\\\\):\\\\s*\\\\w+(?:\\\\W+\\w+){1,2}\")\n Key word\\(s\\): \\s* \\w+ (?:... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376039",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7766771/"
] |
74,376,057 | <p>I need to clone a project of my company on my local machine.</p>
<p>Problem: There is a module required in the main <strong>composer.json</strong> from our old agency which does not exist anymore, so I don't have the access keys needed to download it, BUT I have the latest code of that module.</p>
<p>The composer.js... | [
{
"answer_id": 74377053,
"author": "Black",
"author_id": 4684797,
"author_profile": "https://Stackoverflow.com/users/4684797",
"pm_score": 0,
"selected": false,
"text": "\"autoload\": {\n \"psr-4\": {\n \"RandomAgency\\\\Import\\\\\": \"vendor/random-agency/import\"\n },\n"
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376057",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4684797/"
] |
74,376,061 | <p>The section I am doing is just 6 cards, 3 cards in a row of 2. When the screen goes to small (mobile phone size) I want each card just to be on their own row. Each card showing one by one as the user scrolls.</p>
<p>It functions this way when I resize the screen however, when I go to google tools, it does not show m... | [
{
"answer_id": 74377053,
"author": "Black",
"author_id": 4684797,
"author_profile": "https://Stackoverflow.com/users/4684797",
"pm_score": 0,
"selected": false,
"text": "\"autoload\": {\n \"psr-4\": {\n \"RandomAgency\\\\Import\\\\\": \"vendor/random-agency/import\"\n },\n"
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376061",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16644505/"
] |
74,376,091 | <p>I am using a nested loop, and I want my inner loop to start from the index of the outer loop.</p>
<p>How can I implement this?</p>
<p>I want <code>j</code> to run from <code>i</code> till the end of the array.</p>
<pre><code>nums = [2,7,11,15]
for i in nums:
for j in nums:
print(j)
</code></pre>
| [
{
"answer_id": 74376121,
"author": "Piotr Żak",
"author_id": 9455902,
"author_profile": "https://Stackoverflow.com/users/9455902",
"pm_score": 1,
"selected": false,
"text": "nums = [2,7,11,15]\n\nfor i, val in enumerate(nums):\n for j in nums[i:]:\n print(j)\n"
},
{
"an... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376091",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18003088/"
] |
74,376,103 | <p>I get a json file from a server in my Unity script. The json file looks like this.</p>
<pre><code>{
"drones": [
[
0.0,
0.0,
0.0,
1.0,
0.0,
],
[
0.0,
0.0,
1.0,
1.0,
0.0,
],
[
0.0,
0.0,
1.0,
... | [
{
"answer_id": 74376260,
"author": "Serge",
"author_id": 11392290,
"author_profile": "https://Stackoverflow.com/users/11392290",
"pm_score": 1,
"selected": true,
"text": "int[][] drones= JObject.Parse(incoming_data)[\"drones\"].ToObject<int[][]>();\n"
},
{
"answer_id": 74376268,
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376103",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459630/"
] |
74,376,112 | <p>I'm creating a blog with ReactJS. I have a data component that only contains my data for each articles. I'm able to show all my list of articles on my blog page. The problems comes when I click on an article. I'm able to get the ID in the URL and other params and show it in my article.</p>
<p>The problem: I'd like t... | [
{
"answer_id": 74376163,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 1,
"selected": false,
"text": "useEffect(() => {\n if(id){\n let blog = posts.find((blog) => blog.id === parseInt(id));\n if (blog) ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376112",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17026389/"
] |
74,376,115 | <p>Im in east 8+ timezone, and this expression return nil on my device.</p>
<p>I know it returned a value counting my timezone infomation. But, Why? I don't get it. How this function implemented and what puporse of it?
Thanks.</p>
| [
{
"answer_id": 74376163,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 1,
"selected": false,
"text": "useEffect(() => {\n if(id){\n let blog = posts.find((blog) => blog.id === parseInt(id));\n if (blog) ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376115",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1773317/"
] |
74,376,134 | <p>I have txt file with 7 column...I want to mutiply a 3rd column with a constant number keeping all other column same and then output the file containing all the columns. Anyone can help?</p>
<pre><code>1 2 1
2 2 1
3 2 1
</code></pre>
<p>mutiplying column 3 with "14" the output should be like</p>
<pre><code>... | [
{
"answer_id": 74376163,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 1,
"selected": false,
"text": "useEffect(() => {\n if(id){\n let blog = posts.find((blog) => blog.id === parseInt(id));\n if (blog) ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376134",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20386542/"
] |
74,376,138 | <p>I have a date in format <code>dd/mm/yyyy</code>. I want to subtract one month from it.</p>
<p>I am using this code but the output is "09/10/2020" I don't know why my code does the subtraction of the year -2 also.</p>
<p>This is my request</p>
<pre class="lang-sql prettyprint-override"><code>SELECT
FORM... | [
{
"answer_id": 74376163,
"author": "Sachila Ranawaka",
"author_id": 6428638,
"author_profile": "https://Stackoverflow.com/users/6428638",
"pm_score": 1,
"selected": false,
"text": "useEffect(() => {\n if(id){\n let blog = posts.find((blog) => blog.id === parseInt(id));\n if (blog) ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376138",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16976676/"
] |
74,376,164 | <p>I am trying to add an array element inside the object but if I type text all the text boxes show the text and the text is added only to the first element . even if i added text in second and third text box it is addding into the first tag list plz help me how to fix it</p>
<pre><code>import React, { useState } from... | [
{
"answer_id": 74376373,
"author": "Bhavin Parghi",
"author_id": 6148640,
"author_profile": "https://Stackoverflow.com/users/6148640",
"pm_score": 0,
"selected": false,
"text": "<button onClick={() => handleClick(cid)}>add tag</button>\n const handleClick = (tagIndex) => {\n setSynony... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376164",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9994689/"
] |
74,376,174 | <p>I have a list like this:</p>
<pre><code>test = ["Similar to Stxbp2: Syntaxin-binding protein 2 (Mus musculus)", "Protein of unknown function", "Similar to rab18b: Ras-related protein Rab-18-B (Danio rerio)", "Protein of unknown function", "Protein of unknown function"... | [
{
"answer_id": 74376242,
"author": "It_is_Chris",
"author_id": 9177877,
"author_profile": "https://Stackoverflow.com/users/9177877",
"pm_score": 2,
"selected": false,
"text": "str.startswith str.split : [x[11:].split(':', 1)[0] if x.startswith('Similar to') else 'Unknown' for x in test ]... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376174",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12512945/"
] |
74,376,188 | <p>I am attempting to use the FPDF (<a href="http://www.fpdf.org/" rel="nofollow noreferrer">http://www.fpdf.org/</a>) PHP addon for my website that uses Laravel. I want to be able to dynamically create a PDF.</p>
<p>I have stored the libraries' files in the folder: '/public/vendor'.
This is what I have so far:</p>
<pr... | [
{
"answer_id": 74376426,
"author": "stefket",
"author_id": 2499739,
"author_profile": "https://Stackoverflow.com/users/2499739",
"pm_score": 0,
"selected": false,
"text": " $pdf = new \\Fpdf\\Fpdf('P', 'pt', array(500,233));\n"
},
{
"answer_id": 74376479,
"author": "Richard L... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376188",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13544299/"
] |
74,376,191 | <p>I need to update a MySql database from inside a JS function within a WordPress Woocommerce page. I'm using Ajax to do this. The following code works fine as a stand-alone code but when I put it into the WordPress page (on my localhost) it throws an error 500. Also I put the required data (which will eventually be a ... | [
{
"answer_id": 74376545,
"author": "Richard Leishman",
"author_id": 17473064,
"author_profile": "https://Stackoverflow.com/users/17473064",
"pm_score": -1,
"selected": false,
"text": "global $wpdb;\n$results = $wpdb->query($wpdb->prepare( 'UPDATE db_name SET column = 'Some Value' WHERE i... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376191",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18494930/"
] |
74,376,221 | <p>I have a file <code>data.php</code> looks like the below:</p>
<pre><code>$first_data = 0;
$second_data = 0;
$third_data = 0;
</code></pre>
<p>I have three HTML checkbox on frontend and I would like to store the value into <code>data.php</code>.</p>
<p>( The value is <code>1</code> if it's checked )</p>
<p>In <code>p... | [
{
"answer_id": 74376348,
"author": "leighboz",
"author_id": 1807307,
"author_profile": "https://Stackoverflow.com/users/1807307",
"pm_score": 0,
"selected": false,
"text": "FILE_APPEND file_put_contents ( $dir, preg_replace ( $find_third_data, $replace_third_data, $file_content ), FILE_A... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376221",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20454874/"
] |
74,376,254 | <p>In my XML file [studentinfo.xml] some tags have namespace prefixes, is there a way to loop through the xml file and parse tag content [all sibling and child tags] without defining the URI/URL for namespace?</p>
<p>If you have another way of parsing the xml file not using pandas I am open to any and all solutions.</p... | [
{
"answer_id": 74376348,
"author": "leighboz",
"author_id": 1807307,
"author_profile": "https://Stackoverflow.com/users/1807307",
"pm_score": 0,
"selected": false,
"text": "FILE_APPEND file_put_contents ( $dir, preg_replace ( $find_third_data, $replace_third_data, $file_content ), FILE_A... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376254",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18696224/"
] |
74,376,271 | <p>I am trying to create a circle css and add some more changes to it,</p>
<p>Here is my code for circles</p>
<pre><code>.container {
display: flex;
flex-wrap: nowrap;
width: 200px;
height: 50px;
}
.holder {
margin-right: 5px;
width: 30px;
height: 30px;
border-radius: 50%;
}
.h1 {
background: blue;
}
... | [
{
"answer_id": 74376630,
"author": "Farbod Shabani",
"author_id": 14712252,
"author_profile": "https://Stackoverflow.com/users/14712252",
"pm_score": 2,
"selected": true,
"text": ".container {\n display: flex;\n flex-wrap: nowrap;\n width: 200px;\n height: 50px;\n}\n\n.holder {\n ma... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376271",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19958310/"
] |
74,376,312 | <p>I'm getting this error when trying to build a React native App (npm run android)</p>
<p>error: package com.facebook.react.modules.storage does not exist
import com.facebook.react.modules.storage.ReactDatabaseSupplier;</p>
<p>error: package com.facebook.react.modules.storage does not exist
com.facebook.react.modules.... | [
{
"answer_id": 74462077,
"author": "amirhosein",
"author_id": 7858922,
"author_profile": "https://Stackoverflow.com/users/7858922",
"pm_score": 0,
"selected": false,
"text": "android/build.gradle def REACT_NATIVE_VERSION = new File(['node', '--print',\"JSON.parse(require('fs').readFileSy... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376312",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14914588/"
] |
74,376,313 | <p>this is what I have:</p>
<p><code>"de-de": "This is a description for Process\r\nHere is no line break"</code></p>
<p>I want to replace the \r\n with an <code><br></code> tag</p>
<p>This is what I am trying:</p>
<pre><code><p
v-if="process.description"
class="des... | [
{
"answer_id": 74376466,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 0,
"selected": false,
"text": "<pre> <pre>"
},
{
"answer_id": 74378141,
"author": "Rohìt Jíndal",
"author_id": 4116300,
"author_profile... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376313",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18456799/"
] |
74,376,338 | <p>I am a Beginner in Python and i made this login system with number of tries. I think it can be simplified Can anyone help?</p>
<pre><code>a=int(input("Enter the Password: "))
i=5
if a==1234:
print("ACCESS GRANTED")
while not a==1234:
print(f"INVALID PASSWORD ( {i} times ... | [
{
"answer_id": 74376466,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 0,
"selected": false,
"text": "<pre> <pre>"
},
{
"answer_id": 74378141,
"author": "Rohìt Jíndal",
"author_id": 4116300,
"author_profile... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376338",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459835/"
] |
74,376,357 | <p>I'm new to these wanderings, sorry if it's a stupid question. but can they enlighten me what what's doing there?</p>
<pre><code>char *ft_strchr(char *s, int c)
{
int i;
i = 0;
if (!s)
return (0);
if (c == '\0')
return ((char *)&s[ft_strlen(s)]); // THIS LINE
while (s[i] !... | [
{
"answer_id": 74376472,
"author": "Some programmer dude",
"author_id": 440558,
"author_profile": "https://Stackoverflow.com/users/440558",
"pm_score": 2,
"selected": false,
"text": "& &s[0] s s i &s[i] '\\0' char hello[] = \"Hello world\"; // An array of 12 characters, including termin... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376357",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19766668/"
] |
74,376,397 | <p>I am having an issue returning a component depending on a value. So firstly I have created state called activeIndex defaulted to 1, I then have 3 buttons that when clicked will change this state to either 1, 2 or 3 this works fine. Then the buttons also run a function called showTab() this checks the value of active... | [
{
"answer_id": 74376472,
"author": "Some programmer dude",
"author_id": 440558,
"author_profile": "https://Stackoverflow.com/users/440558",
"pm_score": 2,
"selected": false,
"text": "& &s[0] s s i &s[i] '\\0' char hello[] = \"Hello world\"; // An array of 12 characters, including termin... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376397",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13821506/"
] |
74,376,401 | <p>I have Raw query running as</p>
<pre><code>select meeting.id, GROUP_CONCAT(users.name separator " | ") AS present_user_id from `meeting` left join `users` on JSON_CONTAINS(meeting.present_user_id, JSON_ARRAY(users.id), '$') group by `meeting`.`id`
</code></pre>
<p>Which provide proper result, I tried to co... | [
{
"answer_id": 74376506,
"author": "Techno",
"author_id": 2595985,
"author_profile": "https://Stackoverflow.com/users/2595985",
"pm_score": 1,
"selected": false,
"text": "$result = DB::select('\n select \n meeting.id, \n GROUP_CONCAT(users.name separator \" | \") AS present_use... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376401",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2293790/"
] |
74,376,412 | <p>Why does C# not allow to concat methods with <code>?.</code> in chain?</p>
<pre class="lang-cs prettyprint-override"><code>class X {
public static Timestamp ToTimestamp(this System.DateTime dateTime);
public void Demo()
{
System.DateTime? dateTime = GetFromSomewhere();
Timestamp? good = (dateTime?.ToU... | [
{
"answer_id": 74376605,
"author": "sommmen",
"author_id": 4122889,
"author_profile": "https://Stackoverflow.com/users/4122889",
"pm_score": 0,
"selected": false,
"text": "Timestamp? bad = dateTime?.ToUniversalTime()?.ToTimestamp();\n ToUniversalTime() DateTime dateTime?.ToUniversalTime(... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376412",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/892278/"
] |
74,376,416 | <p>Based on this result from an API</p>
<pre><code>"name": {
"common": "Italy",
"official": "Italian Republic",
"nativeName": {
"ita": {
"official": "Repubblica italiana",
"common&q... | [
{
"answer_id": 74376519,
"author": "RiggsFolly",
"author_id": 2310830,
"author_profile": "https://Stackoverflow.com/users/2310830",
"pm_score": 0,
"selected": false,
"text": "common $json = '{\n \"name\": {\n \"common\": \"Italy\",\n \"official\": \"Italian Republic\",\n \"na... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376416",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14299372/"
] |
74,376,432 | <p>I'm trying to put a 'mask' over a div that contains scrollable content using CSS <code>position: sticky</code>. I want the mask to overlay the content but <em>not</em> the scrollbar. In addition, the container height needs to be defined using <code>max-height</code> instead of <code>height</code>. I've almost got... | [
{
"answer_id": 74376519,
"author": "RiggsFolly",
"author_id": 2310830,
"author_profile": "https://Stackoverflow.com/users/2310830",
"pm_score": 0,
"selected": false,
"text": "common $json = '{\n \"name\": {\n \"common\": \"Italy\",\n \"official\": \"Italian Republic\",\n \"na... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376432",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/178757/"
] |
74,376,442 | <p>I am struggling to make the two numbers i put in the text field multiply and show me the answer to the multiplication. Here is how it should look like when i click the multiply numbers button:(<a href="https://i.stack.imgur.com/WXEkm.png" rel="nofollow noreferrer">https://i.stack.imgur.com/WXEkm.png</a>)](<a href="h... | [
{
"answer_id": 74376586,
"author": "XCS",
"author_id": 407650,
"author_profile": "https://Stackoverflow.com/users/407650",
"pm_score": 0,
"selected": false,
"text": " var number1 = userInput1.value;\n var number2 = userInput2.value;\n\n function getMultiplication(number1, ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376442",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20055080/"
] |
74,376,447 | <p>I have a csv file. The columns are ['A' 'B' 'C'], and there are 1000 rows of original data.
A B C
1 0 1
-1 2 0
.
.
.
1 0 0.
So I need 40% of these data in one csv_file, 60 % in the other. But first, the rows must be shuffled randomly. Hopefully using the pandas module in python.</p>
<p>I tried</p>
<pre class=... | [
{
"answer_id": 74376659,
"author": "Bhargav",
"author_id": 15358800,
"author_profile": "https://Stackoverflow.com/users/15358800",
"pm_score": 2,
"selected": true,
"text": "import numpy as np\nimport pandas as pd\n\n\nper = 40\nmask =int(len(df))\n\nperdf=df.head(int((mask*(per/100))))\n... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376447",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459857/"
] |
74,376,454 | <p>please help me solve the problem.
The table:</p>
<p>id_client, values</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>IDs</th>
<th>values</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>0,46</td>
</tr>
<tr>
<td>2</td>
<td>25%</td>
</tr>
<tr>
<td>3</td>
<td>No information</td>
</tr>
<tr>
... | [
{
"answer_id": 74376554,
"author": "Tim Biegeleisen",
"author_id": 1863229,
"author_profile": "https://Stackoverflow.com/users/1863229",
"pm_score": 3,
"selected": true,
"text": "SELECT\n id_client,\n REGEXP_SUBSTR(values, '[0-9]+([,.][0-9]+)?') AS values\nFROM yourTable;\n values"... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376454",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13277319/"
] |
74,376,469 | <p>Is there a way to simplify these methods? They are the same except for a different method being called.</p>
<pre><code>private async Task ChangePresence(bool args, int voteId)
{
if (GeneralMeetingState.GeneralMeeting != null)
{
_spinnerVisible = true;
await AgendaItemsDet... | [
{
"answer_id": 74376554,
"author": "Tim Biegeleisen",
"author_id": 1863229,
"author_profile": "https://Stackoverflow.com/users/1863229",
"pm_score": 3,
"selected": true,
"text": "SELECT\n id_client,\n REGEXP_SUBSTR(values, '[0-9]+([,.][0-9]+)?') AS values\nFROM yourTable;\n values"... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376469",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17421581/"
] |
74,376,489 | <p>I'm doing some Chinese zodiac assignment for my programming course in C, and I'm not sure if there's a way I can write this doe in much less lines:</p>
<pre><code>int main() {
int year;
printf("Enter your year of birth: \n");
scanf_s("%i", &year);
if (year % 12 == 0) {
return 0;
} else... | [
{
"answer_id": 74376554,
"author": "Tim Biegeleisen",
"author_id": 1863229,
"author_profile": "https://Stackoverflow.com/users/1863229",
"pm_score": 3,
"selected": true,
"text": "SELECT\n id_client,\n REGEXP_SUBSTR(values, '[0-9]+([,.][0-9]+)?') AS values\nFROM yourTable;\n values"... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376489",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459895/"
] |
74,376,512 | <p>Suppose I have a data frame that has the following elements say:</p>
<p><code> Element</code></p>
<p><code>0 a_1</code></p>
<p><code>1 a_2</code></p>
<p><code>2 b_1</code></p>
<p><code>3 a_3</code></p>
<p><code>4 b_2</code></p>
<p><code>.....</code></p>
<p>and so on.</p>
<p>Now sup... | [
{
"answer_id": 74376598,
"author": "mozway",
"author_id": 16343464,
"author_profile": "https://Stackoverflow.com/users/16343464",
"pm_score": 3,
"selected": true,
"text": "map d = {'A': ['a_1', 'a_2', 'a_3'],\n 'B': ['b_1', 'b_2'],\n }\n\nd2 = {k: v for v, l in d.items() for k in ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376512",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459948/"
] |
74,376,531 | <p>I am following a tutorial on Udemy to learn Angular, the instructor provided the code, but each lesson is a new project in a new folder. I would like to merge all the folders into a single repository, so that each folder is a commit. How could I do that?.</p>
<p>This is a screenshot of a section of the course. As I ... | [
{
"answer_id": 74376629,
"author": "Branson Smith",
"author_id": 11329158,
"author_profile": "https://Stackoverflow.com/users/11329158",
"pm_score": 0,
"selected": false,
"text": "git init"
},
{
"answer_id": 74376645,
"author": "eftshift0",
"author_id": 2437508,
"auth... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376531",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13463660/"
] |
74,376,571 | <p>I can graph it using matplotlib:</p>
<pre><code>import matplotlib.pyplot as plt
import numpy as np
x = np.array([5,7,8,7,2,17,2,9,4,11,12,9,6])
y = np.array([99,86,87,88,111,86,103,87,94,78,77,85,86])
plt.scatter(x, y)
plt.show()
</code></pre>
<p>credit: <a href="https://www.w3schools.com/python/matplotlib_scatter... | [
{
"answer_id": 74376629,
"author": "Branson Smith",
"author_id": 11329158,
"author_profile": "https://Stackoverflow.com/users/11329158",
"pm_score": 0,
"selected": false,
"text": "git init"
},
{
"answer_id": 74376645,
"author": "eftshift0",
"author_id": 2437508,
"auth... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376571",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459994/"
] |
74,376,572 | <p>I have one dataframe (X) that looks like</p>
<pre><code>label1 label2
1 2
1 3
1 4
2 1
2 3
2 4
</code></pre>
<p>And another (Y) that looks like</p>
<pre><code>label COLONY
1 5
2 5
3 5
4 6
</code></pre>
<p>I have compared the labels in dataframe ... | [
{
"answer_id": 74377323,
"author": "islem",
"author_id": 11952767,
"author_profile": "https://Stackoverflow.com/users/11952767",
"pm_score": 0,
"selected": false,
"text": "library(dplyr)\n\n# 7 don't exist in Y$label\nX=data.frame(label1=c(7,1,1,2,2,2,3), label2=c(2,3,4,1,3,4,4))\nY=dat... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376572",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11697741/"
] |
74,376,574 | <p>I have generated answer buttons and when I click the answer button color is not changing. Can you help me to sort this out. Here all I want is to change the color when ever I click a button. Please help me out since I'm very new to flutter. Thank you very much.</p>
<pre><code>import 'package:flutter/material.dart';
... | [
{
"answer_id": 74377323,
"author": "islem",
"author_id": 11952767,
"author_profile": "https://Stackoverflow.com/users/11952767",
"pm_score": 0,
"selected": false,
"text": "library(dplyr)\n\n# 7 don't exist in Y$label\nX=data.frame(label1=c(7,1,1,2,2,2,3), label2=c(2,3,4,1,3,4,4))\nY=dat... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376574",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20455262/"
] |
74,376,580 | <p>I need to create a new column %age that returns the value by taking the value in the Subject column of that row to find the value in the column name that matches the value in the subject column.</p>
<p><a href="https://i.stack.imgur.com/e9Ufw.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/e9Ufw.p... | [
{
"answer_id": 74377323,
"author": "islem",
"author_id": 11952767,
"author_profile": "https://Stackoverflow.com/users/11952767",
"pm_score": 0,
"selected": false,
"text": "library(dplyr)\n\n# 7 don't exist in Y$label\nX=data.frame(label1=c(7,1,1,2,2,2,3), label2=c(2,3,4,1,3,4,4))\nY=dat... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376580",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3094480/"
] |
74,376,589 | <p>I am looking to calculate the vote share for a candidate in a particular district for a particular election.</p>
<p>I've got a dataset that gives me the party of the candidate, the district that they ran in, and the year of the election.</p>
<p>However, I have their competitors as well and want to calculate the vote... | [
{
"answer_id": 74376735,
"author": "Celius Stingher",
"author_id": 11897007,
"author_profile": "https://Stackoverflow.com/users/11897007",
"pm_score": 0,
"selected": false,
"text": "transform() df['Dem_votes_share'] = df.groupby('party')['candidatevotes'].transform(lambda x: sum(x)/df['c... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376589",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12394134/"
] |
74,376,592 | <p>I have a data</p>
<pre><code>const Data = [
{
id: '1',
title: 'Blablab<b>labl</b>abla',
},
{
id: '2',
title: '2Blablab<b>labl</b>abla',
},
];
</code></pre>
<p><code><p>{Data.title}</p></code></p>
<pre><code>Output : Blablab<b>labl<... | [
{
"answer_id": 74376735,
"author": "Celius Stingher",
"author_id": 11897007,
"author_profile": "https://Stackoverflow.com/users/11897007",
"pm_score": 0,
"selected": false,
"text": "transform() df['Dem_votes_share'] = df.groupby('party')['candidatevotes'].transform(lambda x: sum(x)/df['c... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376592",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20066668/"
] |
74,376,613 | <p>I am trying to created a weighted average for each week, across multiple columns. My data looks like this:</p>
<pre><code>week <- c(1,1,1,2,2,3)
col_a <- c(1,2,2,4,2,7)
col_b <- c(4,2,3,1,2,5)
col_c <- c(4,2,3,2,2,4)
dfreprex <- data.frame(week,col_a,col_b,col_c)
</code></pre>
<pre><code> week col_a ... | [
{
"answer_id": 74376775,
"author": "Dan Adams",
"author_id": 13210554,
"author_profile": "https://Stackoverflow.com/users/13210554",
"pm_score": 0,
"selected": false,
"text": "stats::weighted.mean() library(tidyverse)\n\ndfreprex <- structure(list(week = c(1, 1, 1, 2, 2, 3), col_a = c(1,... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376613",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20200358/"
] |
74,376,634 | <p>So I was trying to make a function that is required to access the template argument of that class and I don't want to put that function in the class itself.<br />
Here is a example:</p>
<pre><code> template <class Type>
class Node
{
public:
Type Value;
Type* ptr_next;
};
... | [
{
"answer_id": 74376657,
"author": "Jarod42",
"author_id": 2684539,
"author_profile": "https://Stackoverflow.com/users/2684539",
"pm_score": 3,
"selected": false,
"text": "template <typename T>\nvoid element_output(Node<T>* head)\n{\n while (head != nullptr)\n {\n std::cout ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376634",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459932/"
] |
74,376,674 | <p>I have data as follows:</p>
<pre><code>library(data.table)
datA <- fread("A B C
1 1 1
2 2 2")
datB <- fread("A B C
1 1 1
2 2 2
3 3 3")
</code></pre>
<p>I want to figure out which rows are unique (which is the one wi... | [
{
"answer_id": 74376725,
"author": "B. Christian Kamgang",
"author_id": 10848898,
"author_profile": "https://Stackoverflow.com/users/10848898",
"pm_score": 2,
"selected": false,
"text": "library(data.table)\n\ndatB[!datA, on=c(\"A\", \"B\", \"C\")]\n\n A B C\n <int> <int>... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376674",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8071608/"
] |
74,376,692 | <p>I'm trying to create a google sheets function where I use a array function [like UNIQUE() or FILTER()]but the array is returned into one cell and I can specify the location of the value I'm trying to obtain.</p>
<p>I think its analogous to a List in R where you have a list full of a number of string characters and y... | [
{
"answer_id": 74376725,
"author": "B. Christian Kamgang",
"author_id": 10848898,
"author_profile": "https://Stackoverflow.com/users/10848898",
"pm_score": 2,
"selected": false,
"text": "library(data.table)\n\ndatB[!datA, on=c(\"A\", \"B\", \"C\")]\n\n A B C\n <int> <int>... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376692",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459995/"
] |
74,376,704 | <p>im creating a table for my Power Apps Project and i need a foundation so i can add the entries later on.</p>
<p>I want to create a excel-like table with entries. I am using a template from work loking like the first picture<a href="https://i.stack.imgur.com/UF8dt.png" rel="nofollow noreferrer"><img src="https://i.st... | [
{
"answer_id": 74376871,
"author": "Maharkus",
"author_id": 3956676,
"author_profile": "https://Stackoverflow.com/users/3956676",
"pm_score": 2,
"selected": true,
"text": "* {\n font-family: Arial, Helvetica, sans-serif;\n}\n\ntable,\ntr,\ntd {\n border: 1px solid #054F9D;\n border-co... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376704",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20440825/"
] |
74,376,707 | <p>I'm trying to delete some users which are related to a group.</p>
<p>Here is the schema:</p>
<pre><code>model User {
id String @id @default(cuid())
username String
email String @unique
password String?
group GroupUser[]
}
model Group {
id String @id @default(cuid())
name String
user GroupU... | [
{
"answer_id": 74386351,
"author": "Nurul Sundarani",
"author_id": 4154062,
"author_profile": "https://Stackoverflow.com/users/4154062",
"pm_score": 1,
"selected": false,
"text": "GroupUser await prisma.groupuser.delete({\n where: {\n userId_groupId: {\n userId: 'userI... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376707",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17090572/"
] |
74,376,755 | <p>I am using PrimeFaces File Upload with mode="advanced" and multiple="true" just like the demo shows here <a href="https://www.primefaces.org/showcase/ui/file/upload/multiple.xhtml?jfwid=50dd6" rel="nofollow noreferrer">https://www.primefaces.org/showcase/ui/file/upload/multiple.xhtml?jfwid=50dd6<... | [
{
"answer_id": 74421031,
"author": "Melloware",
"author_id": 502366,
"author_profile": "https://Stackoverflow.com/users/502366",
"pm_score": 0,
"selected": false,
"text": "onAdd onAdd=\"setDirty(true);\"\n onBeforeUnload"
},
{
"answer_id": 74450550,
"author": "Jasper de Vries... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376755",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4816848/"
] |
74,376,768 | <p>I've been learning Java for one week now and I came across this solution for my homework, but I just can't understand how it calculates the sum of numbers.</p>
<p>I've tried to understand it for 1 hour now and I feel so dumb right now.</p>
<p>I pretty much understand that <code>for</code> add to <code>x + 1</code> e... | [
{
"answer_id": 74421031,
"author": "Melloware",
"author_id": 502366,
"author_profile": "https://Stackoverflow.com/users/502366",
"pm_score": 0,
"selected": false,
"text": "onAdd onAdd=\"setDirty(true);\"\n onBeforeUnload"
},
{
"answer_id": 74450550,
"author": "Jasper de Vries... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376768",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459874/"
] |
74,376,779 | <p>I was trying to implement a <code>E lower(E e)</code> method to a BST (Binary Search Tree) data structure. It should work like this - (return the greatest element in this set strictly less than the given element, or null if there is no such element). I am stuck at this problem. Any tips?</p>
<p>For example, if I hav... | [
{
"answer_id": 74377122,
"author": "Omar Ahmed",
"author_id": 20192533,
"author_profile": "https://Stackoverflow.com/users/20192533",
"pm_score": 1,
"selected": false,
"text": " 5\n / \\\n 3 8\n / \\ /\n 2 4 6\n \\\n 7\n lower(8) 7"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376779",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19915802/"
] |
74,376,797 | <p>Trying to type check this code (which works perfectly fine):</p>
<pre><code>x = list(range(10))
for func in min, max, len:
print(func(x))
</code></pre>
<p>results in the following error:</p>
<blockquote>
<p>main.py:3: error: Cannot call function of unknown type</p>
</blockquote>
<p>How should this be handled?</p... | [
{
"answer_id": 74377122,
"author": "Omar Ahmed",
"author_id": 20192533,
"author_profile": "https://Stackoverflow.com/users/20192533",
"pm_score": 1,
"selected": false,
"text": " 5\n / \\\n 3 8\n / \\ /\n 2 4 6\n \\\n 7\n lower(8) 7"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376797",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5218354/"
] |
74,376,811 | <p>I have a state, that I only want to change when a certain funcitonal component is initialised. So I intend to do somethin like this:</p>
<pre class="lang-js prettyprint-override"><code>export default function SalesFeedPage(){
const {salesFeed} = useSelector((state) => state.feedReducer);
const dispatch = useDi... | [
{
"answer_id": 74377122,
"author": "Omar Ahmed",
"author_id": 20192533,
"author_profile": "https://Stackoverflow.com/users/20192533",
"pm_score": 1,
"selected": false,
"text": " 5\n / \\\n 3 8\n / \\ /\n 2 4 6\n \\\n 7\n lower(8) 7"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376811",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6266336/"
] |
74,376,815 | <p>I'm trying to learn Kivy and I can't figure why the add_key() function work with the Checkbox but not with the Spinner ?</p>
<p>I got : AttributeError: 'NoneType' object has no attribute 'add_key' ?</p>
<p>Both custom widget's structure seems identical, the add_key function must be stored in the "MainWidget&quo... | [
{
"answer_id": 74377122,
"author": "Omar Ahmed",
"author_id": 20192533,
"author_profile": "https://Stackoverflow.com/users/20192533",
"pm_score": 1,
"selected": false,
"text": " 5\n / \\\n 3 8\n / \\ /\n 2 4 6\n \\\n 7\n lower(8) 7"
},
... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376815",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20061618/"
] |
74,376,824 | <p>I have a sequence <code>s</code> where I expect each proceeding value to be either the same as the previous one or +1.</p>
<pre><code>s = c(1,1,1,1,2,2,2,-2,3,3,4,8,8,8,9,5,5,12,6)
</code></pre>
<p>What I want:</p>
<pre><code>1,1,1,1,2,2,2,3,3,4,5,5,6
</code></pre>
<p>I've solved this with the following code:</p>
<p... | [
{
"answer_id": 74376982,
"author": "MrFlick",
"author_id": 2372064,
"author_profile": "https://Stackoverflow.com/users/2372064",
"pm_score": 5,
"selected": true,
"text": "s = c(1,1,1,1,2,2,2,-2,3,3,4,8,8,8,9,5,5,12,6)\nincreasing_seq <- function(x) {\n keep <- logical(length(x))\n curr... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376824",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11738400/"
] |
74,376,835 | <p>I am finding the difference between 2 dates in years, but when I select the <strong>31st</strong> date it shows an invalid date so the difference is <code>NaN</code>.</p>
<p>When I use other dates it shows the correct result.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel... | [
{
"answer_id": 74377041,
"author": "Brhaka",
"author_id": 11578778,
"author_profile": "https://Stackoverflow.com/users/11578778",
"pm_score": 1,
"selected": false,
"text": "const selectValue = moment('2022-08-31'); // 2022-08-31 instead of 31-8-2022\nconst today = moment();\nconst yearDi... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376835",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20460020/"
] |
74,376,841 | <h3>The data</h3>
<p>I have JSON data that I want to use in a PDF-report. The PDF-report is created from HTML.</p>
<pre class="lang-json prettyprint-override"><code>[
{
"title": "Chapter 1",
"text": "Some large text"
},
{
"title": &qu... | [
{
"answer_id": 74409477,
"author": "Yang",
"author_id": 20335592,
"author_profile": "https://Stackoverflow.com/users/20335592",
"pm_score": 0,
"selected": false,
"text": "<body style=\"background:rgba(100,100,100,0.5);\">\n<button style=\"position:fixed; width:20; height:20; left:80%; to... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376841",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9401138/"
] |
74,376,855 | <p>friends. I want a function, when I give it arrays, that function will seperate positive and negative numbers from those arrays and push them to negativeNumbers or positiveNumbers.</p>
<p>But as you see below, I can do it for arrayOne. If I want do it with arrayTwo, I have to copy all codes again. Is there any way, I... | [
{
"answer_id": 74376938,
"author": "IT goldman",
"author_id": 3807365,
"author_profile": "https://Stackoverflow.com/users/3807365",
"pm_score": 2,
"selected": true,
"text": "[array, array] {arr1: array, arr2: array} const arrayOne = [-2, 5, -3, 6]\nconst arrayTwo = [-12, 15, -13, 16]\n\n... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376855",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17694846/"
] |
74,376,885 | <p>I have a two inputs in my child component, I would like to pass the event of the inputs to my parent component. In the parent component I have a function which will handle the submission. I have the two useState in the parent component, just in case I need to use it in the future in other condition to ensure the use... | [
{
"answer_id": 74376938,
"author": "IT goldman",
"author_id": 3807365,
"author_profile": "https://Stackoverflow.com/users/3807365",
"pm_score": 2,
"selected": true,
"text": "[array, array] {arr1: array, arr2: array} const arrayOne = [-2, 5, -3, 6]\nconst arrayTwo = [-12, 15, -13, 16]\n\n... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376885",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19400358/"
] |
74,376,903 | <p>My use case is to convert text to speech using Azure and then play it into a virtual microphone.<br></p>
<h1>option 1 - with an intermediate .wav file</h1>
<p>I tried both steps manually on a Jupiter notebook. <br>
The problem is, the output .wav file of Azure cannot be played directly on the python
"error: No ... | [
{
"answer_id": 74376938,
"author": "IT goldman",
"author_id": 3807365,
"author_profile": "https://Stackoverflow.com/users/3807365",
"pm_score": 2,
"selected": true,
"text": "[array, array] {arr1: array, arr2: array} const arrayOne = [-2, 5, -3, 6]\nconst arrayTwo = [-12, 15, -13, 16]\n\n... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376903",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12261081/"
] |
74,376,921 | <p>I've alreaedy looked for a similar question to mine but I couldn't found it.
Whenever you find one, let me know.</p>
<p>I have a df that looks like (in reality this df has three columns and more than 1000 rows):</p>
<pre><code>
Name, Value
Markus, 2
Markus, 4
Markus, 1
Caesar, 77
Caesar, 70
Brutus, 3
Nero, 4
Nero, 9... | [
{
"answer_id": 74377001,
"author": "Jilber Urbina",
"author_id": 1315767,
"author_profile": "https://Stackoverflow.com/users/1315767",
"pm_score": 3,
"selected": true,
"text": "split Name paste0 lst <- split(df, df$Name)\nlapply(1:length(lst), function(i){\n write.csv(lst[[i]], paste0(n... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376921",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16371833/"
] |
74,376,956 | <p><strong>Minimal reproducible code:</strong></p>
<pre class="lang-dart prettyprint-override"><code>enum Foo {
a,
b;
String get name {
switch (this) {
case Foo.a: return 'A';
case Foo.b: return 'B';
}
}
}
void main() {
printEnum<Foo>(Foo.values);
}
void printEnum<T extends Enu... | [
{
"answer_id": 74377485,
"author": "AryaveerSR",
"author_id": 20459167,
"author_profile": "https://Stackoverflow.com/users/20459167",
"pm_score": 1,
"selected": false,
"text": "e dynamic name void printEnum<T extends Enum>(List<T> list) {\n for (var e in list) {\n print((e as dynamic... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376956",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12483095/"
] |
74,376,972 | <p>If I have below table</p>
<pre><code>+-----+-----+---+-----+-----+-----+-----+-----+-----+-----+
| a| b| id|m2000|m2001|m2002|m2003|m2004|m2005
+-----+-----+---+-----+-----+-----+-----+-----+-----+-----+
|a |world| 1| 0| 0| 1| 0| 0| 1|
+-----+-----+---+-----+-----+-----+-----+-... | [
{
"answer_id": 74377485,
"author": "AryaveerSR",
"author_id": 20459167,
"author_profile": "https://Stackoverflow.com/users/20459167",
"pm_score": 1,
"selected": false,
"text": "e dynamic name void printEnum<T extends Enum>(List<T> list) {\n for (var e in list) {\n print((e as dynamic... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376972",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9390633/"
] |
74,376,985 | <p>`</p>
<pre><code>namespace Program
{
class Program
{
static void Main(string[] args)
{
Console.Write("s: ");
string s = Console.ReadLine();
int count = 0;
string[] sp = s.Split(new Char[] {' '}, StringSplitOptions.RemoveEmptyEntries);... | [
{
"answer_id": 74377048,
"author": "vivek nuna",
"author_id": 6527049,
"author_profile": "https://Stackoverflow.com/users/6527049",
"pm_score": 0,
"selected": false,
"text": "string[] arr = new string[] { \"Abc\", \"axy\", \"Abd\"};\nint count = 0;\nforeach (string s1 in arr)\n{\n if ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74376985",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20460210/"
] |
74,377,007 | <p>I face a so strange problem that occurs below on the remote tomcat server but works well on the local.</p>
<pre><code>org.springframework.web.util.NestedServletException: Handler processing failed; nested exception is java.lang.NoSuchMethodError: org.apache.doris.analysis.SqlParser.getSymbolFactory()Ljava_cup/runtim... | [
{
"answer_id": 74377048,
"author": "vivek nuna",
"author_id": 6527049,
"author_profile": "https://Stackoverflow.com/users/6527049",
"pm_score": 0,
"selected": false,
"text": "string[] arr = new string[] { \"Abc\", \"axy\", \"Abd\"};\nint count = 0;\nforeach (string s1 in arr)\n{\n if ... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377007",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8034193/"
] |
74,377,016 | <p>I'm trying to create an interface that other classes in MATLAB will inherit. This interface has a property that holds a function_handle value. The problem I'm running into is that, upon instantiating a concrete class that inherits from this class, I get the message: <code>Error defining property 'MyFuncHandle' of cl... | [
{
"answer_id": 74377500,
"author": "Wolfie",
"author_id": 3978545,
"author_profile": "https://Stackoverflow.com/users/3978545",
"pm_score": 3,
"selected": true,
"text": "classdef (Abstract) IMyInterfaceClass < handle\n properties \n MyFuncHandle(1,1) function_handle = @(varargi... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377016",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/610638/"
] |
74,377,046 | <p>I had to generate random password for temporary entry/login purpose in C#. Now I need to only send 6 digits but no more characters, or special characters. New to the C# world. Hence, I am providing what I have so far.</p>
<p>helper.cs</p>
<pre><code>public static string GenerateRandomPassword()
{
int numsLength ... | [
{
"answer_id": 74377177,
"author": "Denis Schaf",
"author_id": 8463053,
"author_profile": "https://Stackoverflow.com/users/8463053",
"pm_score": 2,
"selected": false,
"text": "Random rnd = new Random();\n\npublic static string GenerateRandomPassword()\n{\n int numsLength = 6;\n str... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377046",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20168338/"
] |
74,377,060 | <p>I developed an Outlook Add-in with a Taskpane and a Command Add-in, using the Yo Office Tool with a Web Add-in and Javascript as Code base. So far everything works like we wanted it except for the Command Add-in where we would like to visually tell the user the actual state of the command. Like with either a changed... | [
{
"answer_id": 74377177,
"author": "Denis Schaf",
"author_id": 8463053,
"author_profile": "https://Stackoverflow.com/users/8463053",
"pm_score": 2,
"selected": false,
"text": "Random rnd = new Random();\n\npublic static string GenerateRandomPassword()\n{\n int numsLength = 6;\n str... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377060",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20459834/"
] |
74,377,138 | <p>I feel at the outset I should mention that this is a purely personal project.</p>
<p>I am looking to scrape car data from a well known car website. Their website for each car "product card" is structured as follows:</p>
<pre><code><section class="product-card-details">
<h3 class=&quo... | [
{
"answer_id": 74378575,
"author": "Eugeny Okulik",
"author_id": 12023661,
"author_profile": "https://Stackoverflow.com/users/12023661",
"pm_score": 1,
"selected": false,
"text": "<html>\n<body>\n<section class=\"product-card-details\">\n <h3 class=\"product-card-details__title\">\nMe... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377138",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6562240/"
] |
74,377,139 | <p>Hello I am new to JavaScript I am trying to get season name when user enters a month name. What am I doing wrong?</p>
<pre class="lang-js prettyprint-override"><code>const takeInput = prompt("Enter the Season Name : ");
let seasons = {
summer: ["may", "june", "july"],
wint... | [
{
"answer_id": 74377640,
"author": "RenaudC5",
"author_id": 11260991,
"author_profile": "https://Stackoverflow.com/users/11260991",
"pm_score": 1,
"selected": false,
"text": "takeInput === seasons.summer\n string seasons.summer false switch if if/else if/else const number = 1;\nswitch(nu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377139",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20460367/"
] |
74,377,203 | <p>I'm currently working on a button, which has 3 elements: An icon (with a fixed size), a title (f.e Buy Now!) and the price of the item.
The price which should be displayed is adaptive, this could be €2,00 or €2000,00. The title is supposed to be centered, based on the Button itself, rather than the area it can occup... | [
{
"answer_id": 74377640,
"author": "RenaudC5",
"author_id": 11260991,
"author_profile": "https://Stackoverflow.com/users/11260991",
"pm_score": 1,
"selected": false,
"text": "takeInput === seasons.summer\n string seasons.summer false switch if if/else if/else const number = 1;\nswitch(nu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377203",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20460334/"
] |
74,377,204 | <p>I have printed out a list of numbers, but I want to make the output 'cleaner'</p>
<pre><code>a,b=3,4
while (b<=1000000):
if b>= 100 and b<=1000000:
print(b, end = ' ')
a,b = b,a+b
</code></pre>
<p>output:</p>
<pre><code>123 199 322 521 843 1364 2207 3571 5778 9349 15127 24476 39603 64079 10... | [
{
"answer_id": 74377640,
"author": "RenaudC5",
"author_id": 11260991,
"author_profile": "https://Stackoverflow.com/users/11260991",
"pm_score": 1,
"selected": false,
"text": "takeInput === seasons.summer\n string seasons.summer false switch if if/else if/else const number = 1;\nswitch(nu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377204",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20460022/"
] |
74,377,218 | <p>I want to sum a bars' varible <code>propVolume</code> back since the one which <code>bar_index</code> I specify via input settings. It works just fine unless I give it <code>bar_index</code> of a bar, which is farer than 103 bars back. In documentation they say that that may be due to shortage of default buffer for ... | [
{
"answer_id": 74377640,
"author": "RenaudC5",
"author_id": 11260991,
"author_profile": "https://Stackoverflow.com/users/11260991",
"pm_score": 1,
"selected": false,
"text": "takeInput === seasons.summer\n string seasons.summer false switch if if/else if/else const number = 1;\nswitch(nu... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377218",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12491450/"
] |
74,377,223 | <pre><code>while True:
#SOME CODE...
ch = input("\nWould you like to try again? Y/N: ").upper()
if ch == 'Y':
continue # continue the whole program
elif:
print("Thanks for using the program.")
break # stops the program
else:
# repeats the Y or N que... | [
{
"answer_id": 74377296,
"author": "chepner",
"author_id": 1126841,
"author_profile": "https://Stackoverflow.com/users/1126841",
"pm_score": 2,
"selected": true,
"text": "while True:\n # do something\n\n while True:\n ch = input(\"Try again\").upper()\n if ch in ['YES',... | 2022/11/09 | [
"https://Stackoverflow.com/questions/74377223",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17442579/"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.