question_id int64 37.6M 73.2M | input_text stringlengths 88 52.4k | output_text stringlengths 37 35.6k | title stringlengths 15 150 | tags stringlengths 1 107 | q_score int64 -19 397 | view_count int64 3 879k | answer_count int64 1 21 | accepted_answer_id int64 37.6M 73.8M | answer_id int64 37.6M 73.8M | a_score int64 -5 1.29k | is_accepted bool 1
class | creation_date stringlengths 20 24 | input_text_instruct stringlengths 251 52.6k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
71,242,303 | How can I convert this pandas dataframe to a list?<p>My sample function that returns a pandas data frame.</p>
<pre class="lang-py prettyprint-override"><code>def myFunction(data, row, col):
return pd.DataFrame(
{
"helloWorld": [data["helloWorld"][row][col]],
}
)
... | <p>Use <code>.values.tolist()</code></p>
<pre class="lang-python3 prettyprint-override"><code>def myFunction(data, row, col):
return pd.DataFrame(
{
"helloWorld": [data["helloWorld"][row][col]],
}
).values.tolist()
</code></pre> | How can I convert this pandas dataframe to a list? | python|pandas|dataframe | -1 | 36 | 1 | 71,242,473 | 71,242,473 | 0 | true | 2022-02-23T18:28:55.133Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I convert this pandas dataframe to a list?<p>My sample function that returns a pandas data frame.</p>
<pre class="lang-py prettyprint-override"><code... |
71,244,971 | How to write the constructor instead of using Lombok to access public level?<p>I changed the access level protected to public but how to write the constructor instead of using Lombok for below code?</p>
<pre><code>@RequiredArgsConstructor(access = AccessLevel.PUBLIC))
public class abc implements xyz<Event, Void> ... | <p>It should be if there are no other <code>final</code> fields defined:</p>
<pre class="lang-java prettyprint-override"><code>public class abc implements xyz<Event, Void> {
@NonNull private final Test<Lock<TransactionLock, TransactionLockId>> test;
public abc(@NotNull Test<Lock<Transa... | How to write the constructor instead of using Lombok to access public level? | java|constructor|lombok|access-levels | -1 | 28 | 1 | 71,245,003 | 71,245,003 | 0 | true | 2022-02-23T22:53:26.383Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to write the constructor instead of using Lombok to access public level?<p>I changed the access level protected to public but how to write the constructo... |
71,246,774 | MySQL: Finding the most efficient use of INNER JOIN with subquery<p>I have a working query using INNER JOIN and a subquery but was wondering if there is a more effient way of writing it.</p>
<pre><code>with prl
as
(
SELECT `number`, creator, notes
FROM ratings
INNER JOIN
projects on ratings.project_id = projects.pr... | <p>It seems like you're using MySQL version that support window function. If so, then try this:</p>
<pre><code>SELECT number, creator, notes
FROM
(SELECT p.number, p.creator, r.notes,
COUNT(creator) OVER (PARTITION BY creator) AS cnt
FROM project p
JOIN rating r ON p.project_id=r.project_id
WHERE r.rating=5
... | MySQL: Finding the most efficient use of INNER JOIN with subquery | mysql|join|in-subquery | -1 | 31 | 1 | 71,247,188 | 71,247,188 | 0 | true | 2022-02-24T03:32:38.217Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
MySQL: Finding the most efficient use of INNER JOIN with subquery<p>I have a working query using INNER JOIN and a subquery but was wondering if there is a mo... |
71,242,884 | How can I approach a function that creates plots based on the amount of columns specified><p>Thanks for stopping by to my question..</p>
<p>Basically, I'm new to Python and I just started school and using it as well.</p>
<p>I am currently facing a challenge about making a linear regression model, but my question is gea... | <p>So, basically, I figured it out...</p>
<p>You need to write a function that uses your dataframe and the columns you want to use. You have to make sure to use * in your columns argument so that you can choose 1 or more arguments (columns in this case).</p>
<p>Then inside your function, you make a for loop in which yo... | How can I approach a function that creates plots based on the amount of columns specified> | python|function|for-loop|matplotlib|plot | -1 | 30 | 1 | 71,252,730 | 71,252,730 | 0 | true | 2022-02-23T19:18:59.387Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I approach a function that creates plots based on the amount of columns specified><p>Thanks for stopping by to my question..</p>
<p>Basically, I'm ne... |
71,258,193 | Full outer join not giving the answer I need<p>I am using PostgreSQL and am having difficulty with getting a series of queries that combine the data from two tables (t1, t2)</p>
<p>t1 is</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>studyida</th>
<th>gender</th>
<th>age</th>
</tr>
</thead... | <p>A full join that includes the age maybe?<br />
And some coalesce's for common fields.</p>
<blockquote>
<pre><code>SELECT DISTINCT
COALESCE(t1.StudyIDA, t2.StudyIDA) AS StudyIDA
, t2.StudyIDB
, COALESCE(t1.gender, t2.gender) AS gender
, t1.age as ageA
, t2.age as ageB
FROM t1
FULL JOIN t2
ON t2.StudyIDA is no... | Full outer join not giving the answer I need | sql|postgresql|outer-join | -1 | 42 | 2 | 71,258,568 | 71,258,568 | 0 | true | 2022-02-24T20:59:16.403Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Full outer join not giving the answer I need<p>I am using PostgreSQL and am having difficulty with getting a series of queries that combine the data from two... |
71,260,745 | Why is expand.grid in R returning <0 rows>?<p>I'm trying to use <code>expand.grid</code> to eventually plot estimates from a statistical model. But the output is:</p>
<pre><code>[1] ID Age Sex Tcoded
<0 rows> (or 0-length row.names)
</code></pre>
<p>code:</p>
<pre><code>new_df <- with(test,
... | <p>Try running each individual part of your problem to see what is happening</p>
<pre><code>with(test,
factor(levels(ID)[1], levels = levels(ID)))
</code></pre>
<p>returns</p>
<pre><code>factor(0)
Levels:
</code></pre>
<p>so has zero length and ruins everything else (because if any element of expland.grid has length... | Why is expand.grid in R returning <0 rows>? | r | -1 | 43 | 2 | 71,260,858 | 71,260,858 | 0 | true | 2022-02-25T03:37:00.930Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why is expand.grid in R returning <0 rows>?<p>I'm trying to use <code>expand.grid</code> to eventually plot estimates from a statistical model. But the outpu... |
71,263,194 | Select localization (language) Anylogic PLE<p>I downloaded Anylogic for Mac and I don't find how to change language. (I found Windows guide, but Mac settings doesn't have this setting) and looks different.</p> | <p>You can set it at the Tools-> Preferences</p>
<p>(FYI AnyLogic does not navigate to these preferences if you use the standard Mac command of CMD + , to get to settings of any applications)</p>
<p><a href="https://i.stack.imgur.com/rprBx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rprBx.png"... | Select localization (language) Anylogic PLE | localization|anylogic | -1 | 38 | 1 | 71,263,351 | 71,263,351 | 0 | true | 2022-02-25T08:41:47.043Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Select localization (language) Anylogic PLE<p>I downloaded Anylogic for Mac and I don't find how to change language. (I found Windows guide, but Mac settings... |
71,197,997 | Material 3 Android - dark theme uses shadows instead of lighter color elevations. Has anyone experienced this? How to solve a problem?<p>MaterialComponents works correctly and uses elevationOverlayColor.
<a href="https://i.stack.imgur.com/sNs8V.png" rel="nofollow noreferrer">enter image description here</a>
But Materia... | <p>After implementing <a href="https://codelabs.developers.google.com/codelabs/apply-dynamic-color#0" rel="nofollow noreferrer">codelab</a> point by point, I achieved the desired result.</p> | Material 3 Android - dark theme uses shadows instead of lighter color elevations. Has anyone experienced this? How to solve a problem? | android|kotlin|material-design | -1 | 289 | 1 | 71,265,373 | 71,265,373 | 0 | true | 2022-02-20T19:29:30.467Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Material 3 Android - dark theme uses shadows instead of lighter color elevations. Has anyone experienced this? How to solve a problem?<p>MaterialComponents w... |
71,276,531 | How to delete the second word using : as separator on java script<p>so i have string like this</p>
<pre><code>accept : menerima
accuse : menuduh
achieve : mencapai
acquire : memperoleh
adapt : menyesuaikan
add : menambahkan
</code></pre>
<p>and how to delete the second word using : as separator,
And make the resu... | <p>A different approach to a regex would be to loop over the lines, and split the <code>:</code> using a map.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>const string = `ac... | How to delete the second word using : as separator on java script | javascript | -1 | 32 | 3 | 71,276,654 | 71,276,654 | 0 | true | 2022-02-26T12:12:09.597Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to delete the second word using : as separator on java script<p>so i have string like this</p>
<pre><code>accept : menerima
accuse : menuduh
achieve : ... |
71,279,928 | Unable to change the Fore color of DataGridview cells<p>I have a Winforms application that was designed in the next manner:
Shell Form (Main form) with panel control shows child forms on it by clicking on buttons .</p>
<pre><code> private void btnInbox_Click(object sender, EventArgs e)
{
OpenChildForm(ne... | <p>Consider using CellFormat event of the DataGridView</p>
<pre><code>using System;
using System.Drawing;
using System.Windows.Forms;
namespace DataGridViewGetCellStyle
{
public partial class DatesForm : Form
{
private readonly DataGridViewCellStyle dataGridViewCellStyle = new DataGridViewCellStyle
... | Unable to change the Fore color of DataGridview cells | c#|.net|winforms|datagridview | -1 | 43 | 1 | 71,280,256 | 71,280,256 | 0 | true | 2022-02-26T20:07:09.117Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Unable to change the Fore color of DataGridview cells<p>I have a Winforms application that was designed in the next manner:
Shell Form (Main form) with panel... |
71,280,444 | The array doesn't behave like an array<p>I'm working with express, node and mongoose. If I access my mongoDB database and console.log it, I get my array:</p>
<pre><code>module.exports ={
stories: function(req, res, next){
Story.find(function(err, stories){
if(err) return handleError(err);
con... | <p>Since stories is an array, you can access the elements inside the array using indexing. In this case if you want to log the username of 1st story, you need to do</p>
<pre><code>console.log(stories[0].username)
</code></pre> | The array doesn't behave like an array | node.js|arrays|json|express|mongoose | -1 | 25 | 2 | 71,280,473 | 71,280,473 | 0 | true | 2022-02-26T21:33:00.170Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
The array doesn't behave like an array<p>I'm working with express, node and mongoose. If I access my mongoDB database and console.log it, I get my array:</p>... |
71,281,386 | How do i call an event inside module.exports?<p>Am trying to have a reaction role type of command but i keep getting this error. I am trying to have a reaction to be added to my embed command. I tried to have the event in the index.js but ofc it didn't work. Any help would be appreciated.</p>
<pre><code>C:\Users\moham\... | <p>Dont add new client events within an event. Instead await reactions from a message.</p>
<pre class="lang-js prettyprint-override"><code>const filter = (reaction, user) => user.id === message.author.id;
message.awaitReactions({filter, time: 60000})
.then(reactions => reactions.first())
.then(reaction => ... | How do i call an event inside module.exports? | javascript|discord.js | -1 | 38 | 1 | 71,281,422 | 71,281,422 | 0 | true | 2022-02-27T01:03:30.290Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do i call an event inside module.exports?<p>Am trying to have a reaction role type of command but i keep getting this error. I am trying to have a reacti... |
71,285,884 | Trying to delete outline on a wordpress site<p>I've created a site through wordpress for casino offers etc. so it has a lot of 'clickable' things.
Thing is when I click on something such as a toggle button or an image linked to a link i get this dotted outline.
Im pretty sure it can be removed with javascript but i don... | <p>figured it out just set</p>
<pre><code>.elementor a{
outline:none
}
``
</code></pre> | Trying to delete outline on a wordpress site | wordpress|elementor | -1 | 23 | 1 | 71,286,003 | 71,286,003 | 0 | true | 2022-02-27T15:07:28.690Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Trying to delete outline on a wordpress site<p>I've created a site through wordpress for casino offers etc. so it has a lot of 'clickable' things.
Thing is w... |
71,287,395 | php -v command in command prompt not working on windows<p>I have downloaded the php v 7.3 from <a href="https://www.php.net/releases/" rel="nofollow noreferrer">https://www.php.net/releases/</a>
after downloading and extracting I have added the path to my envirnoment variables.
but after restarting command prompt and e... | <p>The page you linked to is offering the <em>source code</em> for different versions of PHP; to use them, you would need to compile them for your platform.</p>
<p>If you are looking for Windows binaries, you need to look at <a href="https://windows.php.net/" rel="nofollow noreferrer">https://windows.php.net/</a> which... | php -v command in command prompt not working on windows | php | -1 | 34 | 1 | 71,287,448 | 71,287,448 | 0 | true | 2022-02-27T18:19:24.170Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
php -v command in command prompt not working on windows<p>I have downloaded the php v 7.3 from <a href="https://www.php.net/releases/" rel="nofollow noreferr... |
71,296,368 | Pagination in angular<p>I'm using ngx-pagination</p>
<blockquote>
<p><a href="https://www.npmjs.com/package/ngx-pagination" rel="nofollow noreferrer">https://www.npmjs.com/package/ngx-pagination</a></p>
<p>app.module:</p>
</blockquote>
<pre><code>import { NgxPaginationModule } from 'ngx-pagination';
@NgModule({
decl... | <p>Can you try this ?</p>
<pre><code><li *ngFor="let data of this.lists | paginate: { itemsPerPage: count, currentPage: p } index as i"><a href="javascript:void(0)"> # {{ i+1 }} Test</a></li>
</code></pre> | Pagination in angular | angular|angular-pagination | -1 | 266 | 1 | 71,296,567 | 71,296,567 | 0 | true | 2022-02-28T14:17:44.950Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pagination in angular<p>I'm using ngx-pagination</p>
<blockquote>
<p><a href="https://www.npmjs.com/package/ngx-pagination" rel="nofollow noreferrer">https:/... |
71,302,166 | How can I add a scroll bar to the table contents?<p>Need help getting a scroll wheel to control the overflow created form ejs. it currently makes a scroll wheel on the rigth but when i scroll it moves everything. i only wanna be able to scroll though the different table bodys not the page. Thanks, explination and code ... | <p>I don't know if this is what you need. I create a simple example that allows to you scrolling the table, instead the full page. If this is not what you need, please come back with some parctic example and I will try to check it out.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" dat... | How can I add a scroll bar to the table contents? | javascript|html|css | -1 | 42 | 2 | 71,302,293 | 71,302,293 | 0 | true | 2022-02-28T23:28:40.293Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I add a scroll bar to the table contents?<p>Need help getting a scroll wheel to control the overflow created form ejs. it currently makes a scroll wh... |
71,304,417 | Not finding delete option for the repository<p>Not finding delete option for the repository . Please help
<a href="https://i.stack.imgur.com/JQt37.png" rel="nofollow noreferrer">enter image description here</a></p> | <p>To delete a repository, you need to navigate to <strong><code>Project Settings</code></strong> > <strong><code>Repositories</code></strong>.</p>
<p><a href="https://i.stack.imgur.com/Oe5FW.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Oe5FW.png" alt="enter image description here" /></a></p>
<... | Not finding delete option for the repository | azure-devops | -1 | 40 | 1 | 71,305,364 | 71,305,364 | 0 | true | 2022-03-01T06:14:36.563Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Not finding delete option for the repository<p>Not finding delete option for the repository . Please help
<a href="https://i.stack.imgur.com/JQt37.png" rel="... |
71,313,636 | How to create dynamically variable for setInterval?<p>I create a hmtl page with node and ejs with an unforseeable number of elements. I would like to create a setInterval for some, none or all of those elements, depending what the user is doing.</p>
<p>The problem is, that I am not able to create a dynamically variable... | <p>You're on the right track with an array, but you need to push items onto it:</p>
<pre><code>intervalVar = []
// ...
intervalVar.push(setInterval(showConsole, 1500))
</code></pre>
<p>When you want to cancel an interval, remove it from the array with <code>slice</code> or <code>pop</code>, depending on how you're se... | How to create dynamically variable for setInterval? | javascript|variables|setinterval | -1 | 26 | 1 | 71,313,667 | 71,313,667 | 0 | true | 2022-03-01T19:23:10.230Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to create dynamically variable for setInterval?<p>I create a hmtl page with node and ejs with an unforseeable number of elements. I would like to create ... |
71,323,263 | Is there a specific pattern for tracking Header Referrer Data in IHP apps?<p>Anyone have a recommendation/pattern for tracking HTTP: Referrer header data in an IHP app? I was thinking it might be best to add it to the <code>beforeAction</code> in the <code>Static</code> <code>Controller</code> for the app landing page ... | <p>If you want to track it across the full application, use <code>initContext</code> in <code>FrontController</code>. If you only want it for specific controllers, go with <code>beforeAction</code>.</p>
<p>From a technical standpoint there's no major difference between these two places.</p> | Is there a specific pattern for tracking Header Referrer Data in IHP apps? | ihp | -1 | 29 | 1 | 71,323,786 | 71,323,786 | 0 | true | 2022-03-02T13:09:30.607Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is there a specific pattern for tracking Header Referrer Data in IHP apps?<p>Anyone have a recommendation/pattern for tracking HTTP: Referrer header data in ... |
71,326,091 | Make TextBox Suggestion Filter Not Case Sensitive<p>Good day everyone,
I used this code from this post, <a href="https://stackoverflow.com/questions/51684857/wpf-suggestion-textbox">WPF Suggestion TextBox</a>, to suggest the text on a textbox.</p>
<p>Works like I wanted but there is a problem, it is case sensitive, I s... | <pre><code> x.StartsWith(input, StringComparison.OrdinalIgnoreCase);
</code></pre>
<p>You can ignore case sensitive using this, you can improve other part like _currentSuggestion</p>
<pre><code> !input.Equals(_currentSuggestion, StringComparison.OrdinalIgnoreCase);
</code></pre>
<p>etc...</p> | Make TextBox Suggestion Filter Not Case Sensitive | wpf|filter|textbox|case-sensitive | -1 | 41 | 1 | 71,328,459 | 71,328,459 | 0 | true | 2022-03-02T16:30:39.270Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Make TextBox Suggestion Filter Not Case Sensitive<p>Good day everyone,
I used this code from this post, <a href="https://stackoverflow.com/questions/51684857... |
71,329,044 | swift constrain generic function to non-protocol type without casting<p>I'm writing a parsing library - I have a situation where I want to be able to turn any parser that spits out a list of characters int a parser that spits out a string - eg so I can say something like:</p>
<pre class="lang-swift prettyprint-override... | <p>When you want to constrain an associated type to be an exact concrete type, you use <code>==</code> instead of <code>:</code>.</p>
<pre><code>public func text() -> Parser<String> where T == [Character]
// ^^ instead of a colon
</code></pre> | swift constrain generic function to non-protocol type without casting | swift|generics | -1 | 26 | 1 | 71,329,220 | 71,329,220 | 0 | true | 2022-03-02T20:57:32.260Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
swift constrain generic function to non-protocol type without casting<p>I'm writing a parsing library - I have a situation where I want to be able to turn an... |
71,331,091 | I need help adding something in a Deal Card programm<p>I have this code which is almost done. I only need to add the hand humbers at the begininng of every deal. My problem is that they get repeated after the first one.</p>
<pre><code>public class Cards {
public static void main(String[] args) {
int CARDS_... | <p>Change:</p>
<pre><code>for (int q = 1; q <= PLAYERS; q++){
System.out.println("Hand " + q);
for (int i = 0; i < PLAYERS * CARDS_PER_PLAYER; i++) {
System.out.println(deck[i]);
if (i % CARDS_PER_PLAYER == CARDS_PER_PLAYER - 1)
System.out.println();
}
}
</code><... | I need help adding something in a Deal Card programm | java | -1 | 38 | 1 | 71,331,184 | 71,331,184 | 0 | true | 2022-03-03T01:27:59.830Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I need help adding something in a Deal Card programm<p>I have this code which is almost done. I only need to add the hand humbers at the begininng of every d... |
71,337,369 | JMeter - Capture all the Matches and Write them into a file<p>I have a regular expression which contains multiple matches (17 to be precise). All of these are to be captured and written to a file.</p>
<p>Match No. -1 is used to capture all the matches</p>
<p>Now, am using a ForEach Controller to iterate over these matc... | <ol>
<li><p>There is a red <code>1</code> near to yellow exclamation sign in top-right corner of JMeter GUI which means that your test has failed somewhere somehow</p>
<p><a href="https://i.stack.imgur.com/uhjX6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uhjX6.png" alt="enter image description h... | JMeter - Capture all the Matches and Write them into a file | jmeter|jmeter-5.0 | -1 | 40 | 1 | 71,337,641 | 71,337,641 | 0 | true | 2022-03-03T12:38:57.563Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
JMeter - Capture all the Matches and Write them into a file<p>I have a regular expression which contains multiple matches (17 to be precise). All of these ar... |
71,337,121 | shortest path between two vertices after adding two new edges in a graph<p>Given a weighted(Positive weights) undirected graph G(V,E)...we are given two vertices s,t belongs to V. we have to find two new edges from a list of available edges((a1,b1)...(ak,bk)) to add to tha graph such that the distance between s and t i... | <p>A useful edge must shorten the distance between its vertices.</p>
<pre><code>LOOP over K
Find S shortest path between ak and bk in G
IF new edge weight is greater or equal, discard (ak,bk)
APPLY direct algorithm on remaining available edges.
</code></pre> | shortest path between two vertices after adding two new edges in a graph | graph|distance|shortest | -1 | 285 | 1 | 71,339,268 | 71,339,268 | 0 | true | 2022-03-03T12:19:16.503Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
shortest path between two vertices after adding two new edges in a graph<p>Given a weighted(Positive weights) undirected graph G(V,E)...we are given two vert... |
71,341,404 | How to automatically show an alert dialog without pressing a button in Flutter?<p>I implemented the alert dialog in the initstate() method but Init state is only called once. In my case I want the alert to appear automatically every time a variable value changes for exemple. ( I need it to suddenly pop up during using ... | <p>You could use a <strong>ValueNotifier</strong> and a <strong>ValueListenableBuilder</strong> so that every time the value in the <strong>ValueNotifier</strong> changes, the <strong>ValueListenableBuilder</strong> rebuilds and shows a dialog, like so:</p>
<pre><code>class MyWidget extends StatelessWidget {
Value... | How to automatically show an alert dialog without pressing a button in Flutter? | flutter | -1 | 283 | 1 | 71,342,452 | 71,342,452 | 0 | true | 2022-03-03T17:36:32.333Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to automatically show an alert dialog without pressing a button in Flutter?<p>I implemented the alert dialog in the initstate() method but Init state is ... |
71,342,425 | creating month key from date in objects<p>Here is my data:</p>
<pre><code>{
"_id": ObjectId("6213ba90a013b7c5f1232e1f"),
"name": "name1",
"surname": "surname1",
"newArray": {
"buyDate": ISODate("1975-11-04T13:14:15Z"),
... | <ol>
<li>To get month from date, use <code>$month</code> operator.</li>
<li>To get <code>newArray.buyDate</code>, use <code>newArray.buyDate</code> but not <code>buyDate</code>.</li>
<li><code>$group</code> by <code>newArray.buyMonth</code> but not <code>buyMonth</code>.</li>
<li>Use <code>$sum</code> to calculate sum ... | creating month key from date in objects | mongodb|aggregation-framework | -1 | 18 | 1 | 71,345,291 | 71,345,291 | 0 | true | 2022-03-03T18:59:45.633Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
creating month key from date in objects<p>Here is my data:</p>
<pre><code>{
"_id": ObjectId("6213ba90a013b7c5f1232e1f"),
"name"... |
71,349,634 | Write a program to print first x terms of the series 3N + 2 which are not multiples of 4<pre><code>n = int (input())
for x in range (1, n + 1, 1):
for y in range (1, 100, 1):
z = 3 * y + 2
if z % 4 != 0:
print(z, end=' ')
</code></pre>
<p>This code can print the number which are not the ... | <p>Introduce a counter-variable:</p>
<pre><code>n = int (input())
counter = 0
for x in range (1, n + 1, 1):
for y in range (1, 100, 1):
z = 3 * y + 2
if counter >= 10:
break
if z % 4 != 0:
print(z, end=' ')
counter += 1
</code></pre> | Write a program to print first x terms of the series 3N + 2 which are not multiples of 4 | python | -1 | 1,054 | 4 | 71,349,771 | 71,349,771 | 0 | true | 2022-03-04T09:58:46.327Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Write a program to print first x terms of the series 3N + 2 which are not multiples of 4<pre><code>n = int (input())
for x in range (1, n + 1, 1):
for y ... |
71,343,744 | Moving the camera jerkily Unity,C#<p>I am making a puzzle game with drag-and-drop mechanics. Moving objects is implemented through Configurable Joint. When you click the left mouse button, I put the object attached to the player's body in the Conected body of the dragged object</p>
<p><a href="https://i.stack.imgur.com... | <p>The problem was in the rigidbody of the dragged object, after turning off the interpolation and changing the collision detection to discrete, the camera stopped moving jerkily:
<a href="https://i.stack.imgur.com/G6TOS.png" rel="nofollow noreferrer">Fixed Rigidbody</a></p> | Moving the camera jerkily Unity,C# | c#|unity3d | -1 | 37 | 1 | 71,352,098 | 71,352,098 | 0 | true | 2022-03-03T20:58:47.033Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Moving the camera jerkily Unity,C#<p>I am making a puzzle game with drag-and-drop mechanics. Moving objects is implemented through Configurable Joint. When y... |
71,354,357 | Need help making statistics calulator<p>Currently working on statistics calculator but an error message saying invalid syntax which points at print in the mode section</p>
<pre><code> import statistics
amountOfNumbers = input("How many numbers are you using? ")
usersNumbers = input("What are your numbers... | <p>the problem is on the line before the problem,you need put this:</p>
<p><code>print("Mean: " , statistics.mean(usersNumbers))</code></p>
<p>you forgot the parenthesis, I hope it helps you.</p> | Need help making statistics calulator | python|math|statistics|pycharm|calculator | -1 | 41 | 3 | 71,354,433 | 71,354,433 | 0 | true | 2022-03-04T16:30:11.617Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Need help making statistics calulator<p>Currently working on statistics calculator but an error message saying invalid syntax which points at print in the mo... |
71,361,947 | How Can I Use Data More Efficiently (Economically) With Firebase?<p>How can I use the database efficiently (economically) when fetching data after Firebase has saved new data?</p>
<p>There is a table of cars with models and characteristics of cars. The user will create a list in the My cars table and add the cars he ha... | <p>There is no singular correct answer here, it all depends on the need of your application and your comfort level with various solutions.</p>
<p>Duplicating the data is a common approach in Firebase (and other NoSQL databases), since it means you get the necessary data with the minimum number of API calls, and thus is... | How Can I Use Data More Efficiently (Economically) With Firebase? | json|firebase|firebase-realtime-database | -1 | 27 | 1 | 71,363,419 | 71,363,419 | 0 | true | 2022-03-05T11:54:12.690Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How Can I Use Data More Efficiently (Economically) With Firebase?<p>How can I use the database efficiently (economically) when fetching data after Firebase h... |
71,364,459 | Getting an attribute error when referencing a Tkinter Button in its command function<p>I have a class which is a Tkinter Frame, within it is a Tkinter Button. When I try to change a property of the button within its <code>command</code> function, I get the error <code>AttributeError: 'ButtonsFrame' object has no attrib... | <p>The command should be a pointer to a function</p>
<p>In the code you wrote, the command gets the return value from the function.</p>
<pre><code>command=self.solve_button_clicked()
</code></pre>
<p>The correct way is</p>
<pre><code>command=self.solve_button_clicked
</code></pre> | Getting an attribute error when referencing a Tkinter Button in its command function | python|tkinter | -1 | 22 | 1 | 71,364,487 | 71,364,487 | 0 | true | 2022-03-05T17:38:35.283Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Getting an attribute error when referencing a Tkinter Button in its command function<p>I have a class which is a Tkinter Frame, within it is a Tkinter Button... |
71,367,154 | Function pointer not assigning value in C<p>let me explain my issue
i'm working on a simple program where you define a 2D array, in which you have a robot that starts on position (0, 0). then input a number of expressions ( U - Up, D - Down, L - Left, R - Right). if you input either of those, the 'robot' should change ... | <p>Thats not how to 'pass by refereence ' in C</p>
<p>You need</p>
<pre><code>int check_pos(char expression, int *i, int *j)
...
case 'U':
(*j)++;
returnValue = 1;
break;
</code></pre>
<p>and call it like this</p>
<pre><code> while (check_pos(expression, &current_i, &current_j))
</code></pre> | Function pointer not assigning value in C | c|pointers|matrix|coordinates | -1 | 33 | 1 | 71,367,240 | 71,367,240 | 0 | true | 2022-03-06T01:46:23.857Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Function pointer not assigning value in C<p>let me explain my issue
i'm working on a simple program where you define a 2D array, in which you have a robot th... |
71,364,405 | The argument type 'String?' can't be assigned to the parameter type 'String' in flutter for shared prefrances<p>so I am using shared preferences in a flutter app and I get this error :
<strong>The argument type 'String?' can't be assigned to the parameter type 'String'</strong>
and here is the code:</p>
<pre><code>if (... | <p>After looking into the image posted the line 30 declaration states that:</p>
<pre><code>User? userDetails = result.user;// Which potentially means that variable userDetails could be null
</code></pre>
<p>Where as the class User details are not shared but peaking into the issue I am pretty sure the class <code>User</... | The argument type 'String?' can't be assigned to the parameter type 'String' in flutter for shared prefrances | flutter|dart|sharedpreferences | -1 | 3,345 | 3 | 71,367,967 | 71,367,967 | 0 | true | 2022-03-05T17:31:26.930Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
The argument type 'String?' can't be assigned to the parameter type 'String' in flutter for shared prefrances<p>so I am using shared preferences in a flutter... |
71,372,584 | How can I get the string value of a XML element named "name" with BeatifulSoup4?<p>When I try to parse a XML element (tag) "Name" with <code>BeatifulSoup4</code></p>
<pre class="lang-py prettyprint-override"><code>exemplary_xml = '''
<SomeTag>
<UsualTag>abc</UsualTag>
<Name>xyz... | <p>The way you're using the <code>xml</code> via <code>bs4</code> is odd and deprecated. Use <code>features</code> and then either <code>find()</code> or <code>find_all()</code>.</p>
<p>For example:</p>
<pre class="lang-py prettyprint-override"><code>from bs4 import BeautifulSoup
exemplary_xml = '''
<SomeTag>
... | How can I get the string value of a XML element named "name" with BeatifulSoup4? | python|xml|beautifulsoup|xml-parsing | -1 | 34 | 1 | 71,372,676 | 71,372,676 | 0 | true | 2022-03-06T17:23:15.243Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I get the string value of a XML element named "name" with BeatifulSoup4?<p>When I try to parse a XML element (tag) "Name" with <code>Beatif... |
71,344,820 | Is there a way I can show the "imaginary" negative numbers or whatever numbers are missing past the 33rd integer?<pre><code># This is the original code beginning with the number 777 and I want to show the first 37 numbers.
def Collatz(n):
i = 1
while n != 1:
print(f'{i}. {n}')
if n & 1:
... | <pre><code>Collatz = 777
i = 1
while i != 38:
print(f'{i}. {Collatz}')
if Collatz & 1:
Collatz = 3 * Collatz + 1
else:
Collatz = Collatz // 2
i+=1
</code></pre> | Is there a way I can show the "imaginary" negative numbers or whatever numbers are missing past the 33rd integer? | python|negative-number | -1 | 42 | 2 | 71,373,550 | 71,373,550 | 0 | true | 2022-03-03T23:05:05.173Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is there a way I can show the "imaginary" negative numbers or whatever numbers are missing past the 33rd integer?<pre><code># This is the original code begin... |
71,376,278 | How to webscrape data from only specific cells in python?<p>I am trying to webscrape some data from <a href="https://il.water.usgs.gov/gmaps/precip/" rel="nofollow noreferrer">https://il.water.usgs.gov/gmaps/precip/</a>. I only want specific cells from the row called "RAIN GAGE AT PING TOM PARK AT CHICAGO, IL. On... | <p>Data is dynamically retrieved from another endpoint returning JSON. You could write a function calling that endpoint and pass in location and desired hours</p>
<pre><code>def get_precipitation(location:str, hrs:list):
import requests
url = "https://il.water.usgs.gov/gmaps/precip/data/rainfall_outIL_WSr2... | How to webscrape data from only specific cells in python? | python|web-scraping|beautifulsoup | -1 | 30 | 1 | 71,376,575 | 71,376,575 | 0 | true | 2022-03-07T04:02:13.863Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to webscrape data from only specific cells in python?<p>I am trying to webscrape some data from <a href="https://il.water.usgs.gov/gmaps/precip/" rel="n... |
71,366,203 | Postman returns status 200 OK, but JMeter gives 'Connection timed out'<p>I will try to provide as much as information as I can remember and can share due to sensitive data.</p>
<p><strong>Postman:</strong></p>
<p>I have an GET request which response gives me auth token and I pass that token to rest of the requests. I ... | <ol>
<li><p>If JMeter cannot connect to the server and Postman can most probably it means that networking configuration is not correct.</p>
<p>So check your <a href="https://learning.postman.com/docs/getting-started/proxy/" rel="nofollow noreferrer">Postman proxy settings</a> and make sure that JMeter is <a href="https... | Postman returns status 200 OK, but JMeter gives 'Connection timed out' | jmeter|get|request|postman | -1 | 542 | 1 | 71,376,993 | 71,376,993 | 0 | true | 2022-03-05T21:55:03.193Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Postman returns status 200 OK, but JMeter gives 'Connection timed out'<p>I will try to provide as much as information as I can remember and can share due to ... |
71,378,257 | how to get a value from a th tag containing a nested tag parsing in python?<p>How to get a value from th without a value from tag a</p>
<pre><code><th scope="col">1926
<sup id="cite_ref-2011CH_22-0" class="reference">
<a href="#cite_note-2011CH-22">[... | <p>One approache is to select only the text of your target.</p>
<pre><code>th.find(text=True, recursive=False)
</code></pre>
<h3>Example</h3>
<pre><code>from bs4 import BeautifulSoup
html='''
<th scope="col">1926
<sup id="cite_ref-2011CH_22-0" class="reference">
&l... | how to get a value from a th tag containing a nested tag parsing in python? | python|parsing|beautifulsoup | -1 | 36 | 1 | 71,378,466 | 71,378,466 | 0 | true | 2022-03-07T08:30:37.470Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to get a value from a th tag containing a nested tag parsing in python?<p>How to get a value from th without a value from tag a</p>
<pre><code><th sco... |
71,380,351 | List in list concatenation in python<pre><code>lst = [['cp1', 'cp2'], ['ac1', 'ac2'], ['12/12/2020', '12/12/2020']]
</code></pre>
<p>i want to write in a csv file as below</p>
<pre><code>cp1;ac1;12/12/2020
cp2,ac2,12/12/2020
</code></pre>
<p>but the length of lst is not fixed it is dynamic (here it is 3 but can be N)... | <p>Use zip and csv module:</p>
<pre><code>data = [['cp1', 'cp2'], ['ac1', 'ac2'], ['12/12/2020', '12/12/2020']]
import csv
with open ("test.csv","w", newline="") as f:
writer = csv.writer(f)
writer.writerows(zip(*data))
with open("test.csv") as r:
print(r.read())... | List in list concatenation in python | python|list | -1 | 27 | 3 | 71,380,423 | 71,380,423 | 0 | true | 2022-03-07T11:26:17.617Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
List in list concatenation in python<pre><code>lst = [['cp1', 'cp2'], ['ac1', 'ac2'], ['12/12/2020', '12/12/2020']]
</code></pre>
<p>i want to write in a cs... |
71,392,758 | Asp.Net Core : Calculate two Persian dates and get the age?<p>I have two Persian dates and I want the first date to be subtracted from the second date and to store the number as an age in a variable.</p>
<p>First Date :
<code>1399/01/01</code>
Second Date :
<code>1400/01/01</code>
I want the date to be calculated as fo... | <p>I found the answers to my questions</p>
<pre><code> PersianCalendar pc = new PersianCalendar();
var Birthdate = pc.GetYear(DateTime.Parse(viewmodel.BirthDateDay));
var DateNow = pc.GetYear(DateTime.Now);
var resault = ((Convert.ToInt32(DateNow) - Convert.ToInt32(... | Asp.Net Core : Calculate two Persian dates and get the age? | asp.net-core | -1 | 40 | 2 | 71,395,139 | 71,395,139 | 0 | true | 2022-03-08T09:32:20.263Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Asp.Net Core : Calculate two Persian dates and get the age?<p>I have two Persian dates and I want the first date to be subtracted from the second date and to... |
71,398,307 | How can I convert ellipse to path in Microsoft Blend 2022?<p>I have a problem with converting an ellipse to a path in Microsoft Blend 2022. My first try was WPF App template and .NET 6.0 Framework, but options in Format > Path are disabled.</p>
<p><a href="https://i.stack.imgur.com/1JQhC.png" rel="nofollow noreferre... | <p>I "went back in time" to <strong>Visual Studio / Blend 2017</strong>.</p>
<p><strong>It works with .NET Framework 4.8.</strong></p>
<p>Project created from scratch in Blend 2017, copied MainWindow.xaml file:</p>
<p><a href="https://i.stack.imgur.com/ucz8g.png" rel="nofollow noreferrer"><img src="https://i.... | How can I convert ellipse to path in Microsoft Blend 2022? | expression-blend | -1 | 14 | 1 | 71,398,681 | 71,398,681 | 0 | true | 2022-03-08T16:25:52.913Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I convert ellipse to path in Microsoft Blend 2022?<p>I have a problem with converting an ellipse to a path in Microsoft Blend 2022. My first try was ... |
71,398,696 | Make an application that starts by itself and executes code in the background<p>I am developing a flutter application, however I would like a service to be able to run constantly without stopping in order to make an api request every 15 minutes and then send a notification to the user (Android /IOS). I would also like ... | <p>You don't do it like that on Android. You cannot count on an application not being killed in the background. Instead, you use JobScheduler or WorkManager to set an alarm and wake you up every so often to perform whatever job you need. These methods can also ensure you're scheduled at startup of the phone.</p>
<p>... | Make an application that starts by itself and executes code in the background | android|ios|flutter|notifications|background | -1 | 38 | 1 | 71,399,282 | 71,399,282 | 0 | true | 2022-03-08T16:53:16.647Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Make an application that starts by itself and executes code in the background<p>I am developing a flutter application, however I would like a service to be a... |
71,400,708 | Put some button on image for explain something<p>I saw a picture in the excel learn website . there was some buttons to explain excel buttons.
when click on the picture , menu open and explain that button</p>
<p><a href="https://edu.gcfglobal.org/en/excel2016/getting-started-with-excel/1/" rel="nofollow noreferrer">ple... | <p>Simple example for putting button over an image</p>
<p><a href="https://www.w3schools.com/howto/howto_css_button_on_image.asp" rel="nofollow noreferrer">https://www.w3schools.com/howto/howto_css_button_on_image.asp</a></p> | Put some button on image for explain something | javascript|html|css | -1 | 22 | 1 | 71,400,760 | 71,400,760 | 0 | true | 2022-03-08T19:48:51.913Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Put some button on image for explain something<p>I saw a picture in the excel learn website . there was some buttons to explain excel buttons.
when click on ... |
71,405,128 | Finder toolbar icons are jagged or anti-aliased on non-retina displays<p>I'm trying to create Finder toolbar icons that match the look and feel of Monterey, but they seem to be jagged as if there are issues with anti-aliasing.</p>
<p>Here are the retina icons I'm trying to convert (two on the right):</p>
<p><a href="ht... | <p>Finder has a quirk whereby the alpha layers of toolbar icons get multiplied by two when the window is active. If the Finder window is in the background, however, the icons probably look how'd you expect.</p>
<p>If your icons have any thin graphical element, the anti-aliased pixels will have low alpha values. When th... | Finder toolbar icons are jagged or anti-aliased on non-retina displays | macos|icons|finder | -1 | 45 | 1 | 71,405,129 | 71,405,129 | 0 | true | 2022-03-09T06:24:34.480Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Finder toolbar icons are jagged or anti-aliased on non-retina displays<p>I'm trying to create Finder toolbar icons that match the look and feel of Monterey, ... |
71,414,882 | Set maximum forms can be opened (the exe file can be opened 4 times only)<p>How can I set Maximum forms (exe file) can be opened</p>
<p>(I want to set the exe file can be opened 4 times Only!)</p>
<p><code>MessageBox("You have already opened This exe file 4 times"; </code></p> | <p>you can use this one:</p>
<pre><code>Dim instanceCount As Integer = Process.GetProcessesByName("yourexename").Count()
If instanceCount > 4 then
MessageBox("You have already opened This exe file 4 times")
Environment.Exit(0)
End If
</code></pre> | Set maximum forms can be opened (the exe file can be opened 4 times only) | c#|vb.net | -1 | 41 | 2 | 71,415,026 | 71,415,026 | 0 | true | 2022-03-09T19:15:49.920Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Set maximum forms can be opened (the exe file can be opened 4 times only)<p>How can I set Maximum forms (exe file) can be opened</p>
<p>(I want to set the ex... |
71,414,538 | I cant install cargo afl due to conflict libc in build<p>i run this command for installing afl but got this error :slight_smile:
<code>cargo install --force afl --verbose</code></p>
<pre class="lang-none prettyprint-override"><code>Updating crates.io index
Installing afl v0.12.2
Compiling libc v0.2.119
Compiling semver... | <p>its done.
cargo +nightly install --force afl --verbose</p> | I cant install cargo afl due to conflict libc in build | rust|build|rust-cargo|libc | -1 | 270 | 1 | 71,420,686 | 71,420,686 | 0 | true | 2022-03-09T18:46:39.583Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I cant install cargo afl due to conflict libc in build<p>i run this command for installing afl but got this error :slight_smile:
<code>cargo install --force ... |
71,421,760 | How to close connection at the end of method<p>Hi I wanted to ask about how to close the connection at the end of the method, while second method get called.</p>
<pre><code>@Transactional(value = "transactionManagerDC")
public void Execute()
{
// 1. select from DB - took 2 min
ExecuteAPI()
};
pub... | <p>When a transaction is declared using a @Transactional annotation it will end (commit or rollback) when the program control returns from the annotated method, either normally or when an exception occurs.</p>
<p>To have more control over the transactional execution, I would inject a <code>PlatformTransactionManager</c... | How to close connection at the end of method | java|spring|hibernate|transactions|spring-transactions | -1 | 296 | 2 | 71,422,843 | 71,422,843 | 0 | true | 2022-03-10T09:30:22.737Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to close connection at the end of method<p>Hi I wanted to ask about how to close the connection at the end of the method, while second method get called.... |
71,425,946 | Check variable and send to home page with JS<p>hello I'm using this code to send variables to another page</p>
<pre><code> function store () {
var first = "Foo Bar",
second = ["Hello", "World"];
localStorage.setItem("first", first);
localStorage.setItem("secon... | <p>You need to check <a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage" rel="nofollow noreferrer">localStorage</a> in Page2 if variables are not set, localStorage.getItem will return null and if variables are null redirect to the page1</p>
<p><strong>Page 2</strong></p>
<p><strong>script</s... | Check variable and send to home page with JS | javascript|variables | -1 | 38 | 2 | 71,426,188 | 71,426,188 | 0 | true | 2022-03-10T14:37:26.107Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Check variable and send to home page with JS<p>hello I'm using this code to send variables to another page</p>
<pre><code> function store () {
var first... |
71,194,314 | How can we use python to get sentences from Wikipedia?<pre><code>import Wikipedia
result = Wikipedia("India", sentences = 2)
print(result)
</code></pre>
<p>It gives me an error. Please can you resolve this error?</p> | <pre><code>import wikipedia
result = wikipedia.summary("India", sentences = 2)
print(result)
#use Wikipedia in small case and use summary
</code></pre> | How can we use python to get sentences from Wikipedia? | python | -1 | 43 | 1 | 71,194,319 | 71,194,319 | 0 | true | 2022-02-20T12:15:46.330Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can we use python to get sentences from Wikipedia?<pre><code>import Wikipedia
result = Wikipedia("India", sentences = 2)
print(result)
</code>... |
71,194,216 | How to better organize the hierarchy of classes<p>I have an abstract class Image Filter:</p>
<pre><code>abstract class ImageFilter {
internal abstract val size: Int
fun applyForImage(image: BmpImage) {
//here size is used to calculate the boundaries
//somewhere here applyForOnePixel(data) is cal... | <p>If your <code>GrayscaleFilter</code> should not be modifiable in any way, you can define it as an <code>object</code> instead of a <code>class</code>.</p>
<pre class="lang-kotlin prettyprint-override"><code>object GrayscaleFilter: ImageFilter() {
override val size: Int = TODO("Not yet implemented")
... | How to better organize the hierarchy of classes | java|kotlin|oop | -1 | 34 | 1 | 71,194,312 | 71,194,312 | 0 | true | 2022-02-20T12:00:48.680Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to better organize the hierarchy of classes<p>I have an abstract class Image Filter:</p>
<pre><code>abstract class ImageFilter {
internal abstract va... |
71,379,802 | How to link downloadable files in docusaurus?<p>I want to link downloadable content on my documentation and I tried putting in a link like this:</p>
<pre><code><a
href={
require("@site/static/img/04-api/01/API-Description.png")
.default
} download="file-name"
> download </a&g... | <p>You had to use inline-html with the <code>download</code> attribute and <code>target="_blank"</code></p>
<pre><code>[not working](/logo.png)
<a href={ require("/logo.png").default } download={"origName"}>not working</a>
<a target="_blank" href={ require("... | How to link downloadable files in docusaurus? | reactjs|web|docusaurus | -1 | 269 | 2 | 71,409,223 | 71,409,223 | 0 | true | 2022-03-07T10:39:49.623Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to link downloadable files in docusaurus?<p>I want to link downloadable content on my documentation and I tried putting in a link like this:</p>
<pre><co... |
71,174,797 | Correct usage of data/body with axios in node.js<p>I get the error 'NOT_FOUND' with the error code of 404 when trying this code:</p>
<pre><code> axios.get(`https://api.exchange.bitpanda.com/public/v1/account/deposit/crypto`, {
headers: {
'content-type': 'application/json',
'Authorization': 'Bea... | <p>You get 404 because request to <code>https://api.exchange.bitpanda.com/public/v1/account/deposit/crypto</code> should be <code>POST</code> not <code>GET</code> as per the <a href="https://developers.bitpanda.com/exchange/?shell#deposit-crypto" rel="nofollow noreferrer">documentation</a></p>
<pre><code> axios.post(RE... | Correct usage of data/body with axios in node.js | node.js|axios | -1 | 25 | 1 | 71,175,366 | 71,175,366 | 0 | true | 2022-02-18T14:06:47.173Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Correct usage of data/body with axios in node.js<p>I get the error 'NOT_FOUND' with the error code of 404 when trying this code:</p>
<pre><code> axios.get... |
71,136,687 | SQLite delete the "worst" duplicates<p>I have this table:</p>
<pre><code>CREATE TABLE `laptimes` (
`driver` varchar NOT NULL,
`car` varchar NOT NULL,
`laptimeMs` int NOT NULL,
);
</code></pre>
<p>filled with data like in this example:</p>
<pre><code>| driver| car | laptimeMs|
| ----- | ----- | ---------|
| John ... | <p>I would use exists logic here:</p>
<pre class="lang-sql prettyprint-override"><code>DELETE
FROM laptimes
WHERE EXISTS (
SELECT 1
FROM laptimes t
WHERE t.driver = laptimes.driver AND
t.laptimeMs < laptimes.laptimeMs
);
</code></pre> | SQLite delete the "worst" duplicates | sqlite|duplicates | -1 | 29 | 1 | 71,136,722 | 71,136,722 | 0 | true | 2022-02-16T05:08:38.620Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SQLite delete the "worst" duplicates<p>I have this table:</p>
<pre><code>CREATE TABLE `laptimes` (
`driver` varchar NOT NULL,
`car` varchar NOT NULL,
`l... |
71,227,963 | How do I use an Ubuntu packgage with software running insde docker?<p>I have a node.JS app with a MYSQL database inside a docker container to make it scale easily but I've ran into an issue.</p>
<p>I am using a packgage called <code>node-lame</code>. It uses the lame software in order to edit mp3 files inside my app. T... | <p>You can't use software on the host from inside the container. So you need to have node-lame inside the container.</p>
<p>Add <code>node-lame</code> as a dependency in your package.json file and it'll be installed when your Dockerfile does <code>RUN npm install</code>.</p>
<p>To install lame, add the following line t... | How do I use an Ubuntu packgage with software running insde docker? | docker|docker-compose|lame | -1 | 25 | 1 | 71,228,629 | 71,228,629 | 0 | true | 2022-02-22T20:34:43.373Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I use an Ubuntu packgage with software running insde docker?<p>I have a node.JS app with a MYSQL database inside a docker container to make it scale e... |
71,246,670 | How to add quotes to every 2nd word in a string in R<p>I want to add double quotes around every second word in this single string.</p>
<p>From this</p>
<pre><code>gene_id ENSG00000081237; gene_version 20; transcript_id ENST00000442510; transcript_version 8;
gene_type protein_coding; gene_name CD45A;
</code></pre>
<p>t... | <p>Here is a base R approach.</p>
<p>First remove the <code>;</code> at the end of the string, then split the vector of gene information by <code>;</code>, then split again by empty space " " and save to a new vector <code>vec_apply</code>.</p>
<p>After that, paste back the unmodified split strings together w... | How to add quotes to every 2nd word in a string in R | r|regex|string|double-quotes | -1 | 28 | 2 | 71,246,800 | 71,246,800 | 0 | true | 2022-02-24T03:17:42.480Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add quotes to every 2nd word in a string in R<p>I want to add double quotes around every second word in this single string.</p>
<p>From this</p>
<pre>... |
71,157,791 | How I can count letter in sentence in Python<p>Please help in writing a program that will count the letters 'a' in a sentence. I need to use a 'for' loop.</p>
<pre><code>text = input("Give a sentence and I will count the number of letters 'a'\n")
for letter in text:
a_text = text.count('a')
print(a_t... | <pre><code>text = input("Give a sentence and I will count the number of letters 'a'\n")
count = 0
for letter in text:
if letter == 'a':
count += 1
print("The number of 'a' is:", count)
</code></pre> | How I can count letter in sentence in Python | python | -1 | 40 | 1 | 71,157,819 | 71,157,819 | 0 | true | 2022-02-17T12:02:21.363Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How I can count letter in sentence in Python<p>Please help in writing a program that will count the letters 'a' in a sentence. I need to use a 'for' loop.</p... |
71,123,642 | App crashing two linear layout inside other linear layout with java<p>Hey Everyone I want to make a layout in android studio dynamically(not with xml) the structure will be like :
LinearLayout(Horizontal)
--LinearLayout(Vertical)
----TextView1
----TextView2
--LinearLayout(Vertical)
----TextView3
----TextView4</p>
<p>bu... | <p>why are you setting <code>setContentView</code> multiple times? <code>Activity</code> can contain just one <code>View</code> as content (but this may be <code>ViewGroup</code> with multiple childs). just add inner <code>LinearLayout</code>s to main parent <code>LinearLayout</code> and then call <code>setContentView<... | App crashing two linear layout inside other linear layout with java | java|android | -1 | 30 | 1 | 71,123,745 | 71,123,745 | 0 | true | 2022-02-15T09:01:56.753Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
App crashing two linear layout inside other linear layout with java<p>Hey Everyone I want to make a layout in android studio dynamically(not with xml) the st... |
71,264,260 | Persistence Exception foreign key contraint fails in hibernate<p>I have defined the following two classes in hibernate <br></p>
<pre><code>@Entity
public class Person {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private int id;
private String name;
}
@Entity
public class PhoneNumber {
... | <p>You have a bi-directional relationship, that is why you have to add the <code>PhoneNumber</code>s in your <code>Person</code> too. And use the <code>mappedBy</code> attribute to show that the <code>Person</code> is the inverse side and whenever it is deleted, please delete every phone number also.</p>
<p>Like this:<... | Persistence Exception foreign key contraint fails in hibernate | java|hibernate|jpa|many-to-one | -1 | 30 | 2 | 71,264,480 | 71,264,480 | 0 | true | 2022-02-25T10:12:56.050Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Persistence Exception foreign key contraint fails in hibernate<p>I have defined the following two classes in hibernate <br></p>
<pre><code>@Entity
public cla... |
71,119,791 | Why won't my images show in my HTML file?<p>Is there something wrong with my syntax? I have an images folder located in the same folder as the html file. Images from URLs work fine.
<code><img src="images/ai_1.png" width="500" height="300"/></code></p>
<p><a href="https://i.stack.img... | <p>Given that the directory is named <code>templates</code>…</p>
<p>You have some server-side (or build-time) code which takes a URL and <em>somehow</em> translates that into an instruction to generate an HTML document from that template and other stuff (probably includes and some page specific data).</p>
<p>The relati... | Why won't my images show in my HTML file? | html|image | -1 | 17 | 1 | 71,119,814 | 71,119,814 | 0 | true | 2022-02-15T00:19:35.680Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why won't my images show in my HTML file?<p>Is there something wrong with my syntax? I have an images folder located in the same folder as the html file. Ima... |
71,155,772 | Find the word after specific word<p>i am new in javascript.
I have below code where textarea contains text as...</p>
<pre><code><textarea id="myBox" >
{Picker:} Helper
This is just demo...
</textarea>
<br/>
<span id="ans"></span> <br/>
<input type="butt... | <p>You should start from the index of <code>"{Picker:}"</code> + 9, because the length of the particular string is 9.</p>
<p>Parse till the the index of <code>'\n'</code> which is the line break character.</p>
<p><a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/... | Find the word after specific word | javascript | -1 | 40 | 3 | 71,155,855 | 71,155,855 | 0 | true | 2022-02-17T09:47:52.663Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Find the word after specific word<p>i am new in javascript.
I have below code where textarea contains text as...</p>
<pre><code><textarea id="myBox&... |
71,208,025 | CSS menu, how to select parent<p>I have three items in a navigation menu</p>
<pre><code><nav>
<ul class="menu-topnav menu">
<li class="menu__item menu__item--first-lvl active-trail active">
<a href="/le-reseau-pikard" class="topnav-3-pikard... | <p>Specific to your question, and code example shared, the below should work by using the <code>+</code> next sibling selector.</p>
<pre><code>li.active + li > a.is-active {
pointer-events: none;
opacity: 0.3;
}
</code></pre>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel... | CSS menu, how to select parent | css|menu|parent-child | -1 | 29 | 1 | 71,208,333 | 71,208,333 | 0 | true | 2022-02-21T14:29:51.407Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
CSS menu, how to select parent<p>I have three items in a navigation menu</p>
<pre><code><nav>
<ul class="menu-topnav menu">
... |
71,195,381 | How to put in if statement date format for entry in tkinter?<pre><code> def Verification():
date_format = "%d/%m/%Y"
if (datetime.strptime("1/1/2001", date_format) <= date_ < datetime.strptime("31/1/2008", date_format)):
print('bravo')
date_= datetime.strptim... | <p>I'm not sure I understand your question, so the following is an answer based on what I <em>think</em> you're asking.</p>
<p>It works like this: When the <kbd>Verify</kbd> button is pressed the <code>verification()</code> function will be called which will initially attempt to parse what the user inputted into a <cod... | How to put in if statement date format for entry in tkinter? | python|if-statement|tkinter | -1 | 41 | 1 | 71,196,731 | 71,196,731 | 0 | true | 2022-02-20T14:25:53.993Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to put in if statement date format for entry in tkinter?<pre><code> def Verification():
date_format = "%d/%m/%Y"
if (datetime.strp... |
71,236,013 | Reading CRUD wont show " marks<p>I have created a CRUD system for a contact form.</p>
<p>If i was to input speech marks ("") it will not input anything after and including the speechmarks</p>
<p>I use the VARCHAR datatype in the database and type=text in html</p>
<h2>Example</h2>
<p>In image 1. I have inputte... | <p>I assume you are talking about when you <code>echo</code> existing values into the field when the form loads? If so, then obviously it won't show anything after double-quotes (<code>"</code>), because double-quotes are also used to close the <code>value</code> attribute in the HTML.</p>
<p>So for example if the... | Reading CRUD wont show " marks | php|html | -1 | 28 | 2 | 71,236,167 | 71,236,167 | 0 | true | 2022-02-23T11:23:34.380Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Reading CRUD wont show " marks<p>I have created a CRUD system for a contact form.</p>
<p>If i was to input speech marks ("") it will not input anyt... |
71,141,841 | I am creating a temporary variable "temp" so that I don't change the actual set value but it still is making changes in the original set. WHY?<p>I have an ArrayList of HashSets named "set" and to operate on the individual HashSets I am copying the Set's value to a temporary HashSet "temp" but when I... | <p>This instruction <code>HashSet<Integer> temp = set.get(i);</code> makes you are accessing the same collection that is "inside" <em>set</em> in position <em>i</em>. That's why it's modifying.</p>
<p>You have to create a new collection</p>
<pre><code>Set<Integer> temp = new HashSet<>(set.ge... | I am creating a temporary variable "temp" so that I don't change the actual set value but it still is making changes in the original set. WHY? | java|arraylist|hashset | -1 | 39 | 1 | 71,141,952 | 71,141,952 | 0 | true | 2022-02-16T12:24:57.083Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I am creating a temporary variable "temp" so that I don't change the actual set value but it still is making changes in the original set. WHY?<p>I have an Ar... |
71,245,635 | I dont get why I cant get a json format with requests.Request()?<pre><code>from requests import Request as R
markets = R("GET", "https://ftx.com/api/markets")
print(markets.json())
</code></pre>
<p>Error:
print(markets.json())
TypeError: 'NoneType' object is not callable</p>
<p>Process finished wit... | <p><code>Request</code> is just the object that <em>represents</em> the request. You want <code>requests.request</code> to construct <em>and</em> make the request.</p>
<pre><code>import requests
markets = requests.request("GET", "https://ftx.com/api/markets")
</code></pre>
<p>The <code>json</code> ... | I dont get why I cant get a json format with requests.Request()? | python|python-requests | -1 | 45 | 2 | 71,245,681 | 71,245,681 | 0 | true | 2022-02-24T00:27:30.980Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I dont get why I cant get a json format with requests.Request()?<pre><code>from requests import Request as R
markets = R("GET", "https://ftx.... |
71,264,950 | Media Breakpoints are failing<p>I am missing something really simple here so hopefully somebody can unspin my brain.</p>
<p>I have a page layout working OK but on applying the media breakpoints nothing changes. Below is an example of my CSS. You can see I am just altering the font size to try and get the thing working ... | <p>Like those often missed dashes and slashes the problem was poor syntax in the CSS immediately before my breakpoints and so the breakpoints weren't being processed properly. I'm clocking out for the next two and a half days.</p> | Media Breakpoints are failing | css|breakpoints|bootstrap-5 | -1 | 40 | 3 | 71,267,730 | 71,267,730 | 0 | true | 2022-02-25T11:07:16.527Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Media Breakpoints are failing<p>I am missing something really simple here so hopefully somebody can unspin my brain.</p>
<p>I have a page layout working OK b... |
71,394,266 | am building the facebook gif post project, when i click on the gif it has to dispaly in the text area. But am stuck with type error post.map is nt fun<p>this is my main code, when I click on any gif am getting the data that is stored in the state but when I try to display the data in UI, am getting this below error.
<a... | <p>Looks like you are trying to use map function on an <code>object</code>. You can only use <code>map</code> function directly on <code>arrays</code>.
In your console log, <code>post</code> is an object that contains more objects like <code>data</code> and <code>meta</code>.</p>
<p>Therefore, you need to make the foll... | am building the facebook gif post project, when i click on the gif it has to dispaly in the text area. But am stuck with type error post.map is nt fun | java|reactjs|api | -1 | 36 | 1 | 71,394,447 | 71,394,447 | 0 | true | 2022-03-08T11:26:51.440Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
am building the facebook gif post project, when i click on the gif it has to dispaly in the text area. But am stuck with type error post.map is nt fun<p>this... |
71,194,938 | How do I use a font from Windows 10 and install it in Windows 8.1?<p>There is a font called Bahnschift and I've been wanting to use this font for some projects but unfortunately when I tried to install this font (I'm trying to install the whole font family), all that installs is just Bahnschift Regular and nothing else... | <p>The Banhnschrift font is a variable font. Variable fonts are not supported on Windows 8.1 or below.</p>
<p>For variable fonts that use CFF2 outline data, the font will not work at all on older implementations that don't support variable fonts. If the variable font uses TrueType outlines, then the default instance—an... | How do I use a font from Windows 10 and install it in Windows 8.1? | windows|fonts | -1 | 36 | 2 | 71,225,097 | 71,225,097 | 0 | true | 2022-02-20T13:35:41.507Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I use a font from Windows 10 and install it in Windows 8.1?<p>There is a font called Bahnschift and I've been wanting to use this font for some projec... |
71,101,173 | Java Inheritance: Child class not executing<p>I was practicing inheritance in Java, and faced the following issue:</p>
<p>Code for parent class:</p>
<pre class="lang-java prettyprint-override"><code>public class FEB7 {
String address,name;
void get(String n, String a){
name = n;
address = a;
... | <p>The <code>main</code> method in <code>FEB8</code> has <code>String args</code> as the argument instead of <code>String args[]</code>. Change it to <code>args[]</code> and try again.</p> | Java Inheritance: Child class not executing | java | -1 | 43 | 1 | 71,101,214 | 71,101,214 | 1 | true | 2022-02-13T13:38:29.567Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Java Inheritance: Child class not executing<p>I was practicing inheritance in Java, and faced the following issue:</p>
<p>Code for parent class:</p>
<pre cla... |
71,104,817 | Is it possible to convert a legacy app to UWP using Windows 11 Home?<p>In an <a href="https://www.howtogeek.com/250041/how-to-convert-a-windows-desktop-app-to-a-universal-windows-app/" rel="nofollow noreferrer">article</a> I've read that Windows 10 Professional is required to use Desktop App Converter. Is this still tr... | <p>"Desktop App Converter" has been deprecated. The replacement is the <a href="https://www.microsoft.com/en-us/p/msix-packaging-tool/9n5lw3jbcxkf" rel="nofollow noreferrer">MSIX Packaging Tool</a>. The documentation is on <a href="https://aka.ms/MSIX" rel="nofollow noreferrer">Microsoft Docs</a>.</p> | Is it possible to convert a legacy app to UWP using Windows 11 Home? | windows|uwp|windows-11|desktop-app-converter | -1 | 35 | 1 | 71,106,034 | 71,106,034 | 1 | true | 2022-02-13T21:01:59.697Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is it possible to convert a legacy app to UWP using Windows 11 Home?<p>In an <a href="https://www.howtogeek.com/250041/how-to-convert-a-windows-desktop-app-t... |
71,106,625 | Interactive reabse of commits with last merge shows two extra commits in list of commits to pick/edit<p>I've tried web search and found <a href="https://stackoverflow.com/questions/4783599/rebasing-a-git-merge-commit">Rebasing a Git merge commit</a>, where it is written:</p>
<blockquote>
<p>By default, a rebase will si... | <p>No commit, once made, can ever be changed. Hence the job that <code>git rebase</code> performs is to <em>copy</em> some existing commits (that you like to some extent, but dislike <em>something</em> about those commits) to new and improved—well, you <em>hope</em> improved, anyway—commits. Git then sets up the <em>... | Interactive reabse of commits with last merge shows two extra commits in list of commits to pick/edit | git|merge | -1 | 40 | 1 | 71,107,993 | 71,107,993 | 1 | true | 2022-02-14T02:41:58.557Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Interactive reabse of commits with last merge shows two extra commits in list of commits to pick/edit<p>I've tried web search and found <a href="https://stac... |
71,111,540 | I am having problems with a my function to delete html elements. (First time posting, please be nice)<p>I am a begginer programmer and I am working on my first small project. I decided to make a notes app. It is basically completed, except that I wanted to have a button to delete all completed task and I am having prob... | <p>When you delete elements from an array, its length changes. This is not accounted for in your code.</p>
<p>I find it easiest to iterate backwards in that case:</p>
<pre><code>for (let i = children.length - 1; i >= 0; i--){
//...
</code></pre> | I am having problems with a my function to delete html elements. (First time posting, please be nice) | javascript|for-loop|local-storage | -1 | 30 | 1 | 71,111,599 | 71,111,599 | 1 | true | 2022-02-14T11:59:35.280Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I am having problems with a my function to delete html elements. (First time posting, please be nice)<p>I am a begginer programmer and I am working on my fir... |
71,114,482 | How do I perform a network process in a kotlin coroutine<p>I am attempting to run the getByName method in my android app, but have found that doing so in the main activity is cause for concern. I know I need to use coroutines, or async, or threads. But I'm not sure how to go about this. I'm somewhat self-taught with th... | <p>You are getting exception because you starts your coroutine on main thread.</p>
<p>To perform network request,you need to use background thread .For that you can use " launch " coroutine builder with IO dispatcher to start new coroutine on background thread.</p>
<pre><code>lifecycleScope.launch(Dispatchers... | How do I perform a network process in a kotlin coroutine | android|android-studio|kotlin|networking|kotlin-coroutines | -1 | 539 | 2 | 71,116,100 | 71,116,100 | 1 | true | 2022-02-14T15:43:18.457Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I perform a network process in a kotlin coroutine<p>I am attempting to run the getByName method in my android app, but have found that doing so in the... |
71,121,241 | Python: Question about the usage of max() and min() when the input numbers are two-digit<p>When the code below takes input such as</p>
<p>5 (the length of the next input)
1 3 5 2 4</p>
<p>it accurately returns the maximum number and the minimum number.</p>
<p>However, when the code takes input that includes two-digit n... | <p>nums should be a list of integer and not list of string. currently it is list of string. you need to convert it to list of int.</p>
<p><code>nums = list(map(int, input().split()))</code></p> | Python: Question about the usage of max() and min() when the input numbers are two-digit | python|list|max | -1 | 30 | 2 | 71,121,266 | 71,121,266 | 1 | true | 2022-02-15T04:50:30.510Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Python: Question about the usage of max() and min() when the input numbers are two-digit<p>When the code below takes input such as</p>
<p>5 (the length of th... |
71,121,231 | How do I use try and else in function in python?<p>How do I request and export <em><strong>http</strong></em> file to read if file is not present in my directory?</p>
<p><strong>My code :</strong></p>
<pre><code>def data():
try:
with open('sample.json', 'r') as openfile:
json_object = json.load(openfile)
... | <h3>Code:</h3>
<ul>
<li>Use <code>isfile(<file>)</code> instead, it is a better option in this case.</li>
<li><code>isfile('sample.json')</code> checks if file exists or not.</li>
</ul>
<pre><code>from os.path import isfile
def data():
file='sample.json'
if isfile(file):
with open(file, 'r') as openfile: ... | How do I use try and else in function in python? | python|function|request | -1 | 30 | 1 | 71,121,277 | 71,121,277 | 1 | true | 2022-02-15T04:48:38.013Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I use try and else in function in python?<p>How do I request and export <em><strong>http</strong></em> file to read if file is not present in my direc... |
71,123,521 | Two-step Login using Jmeter<p>I wanted to load test an application but there is a login page with two pages. The app is not signed in, although the username and password are correct.
Maybe someone will have suggestions that I did not do it right</p>
<p><a href="https://i.stack.imgur.com/04Abe.png" rel="nofollow norefer... | <p>It looks like your test plan is good, your app is informing you that the user doesn't exist:</p>
<p><a href="https://i.stack.imgur.com/kElH2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kElH2.png" alt="enter image description here" /></a></p>
<p>Most probably the user you're using for <code>dev... | Two-step Login using Jmeter | jmeter | -1 | 24 | 1 | 71,123,843 | 71,123,843 | 1 | true | 2022-02-15T08:52:30.753Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Two-step Login using Jmeter<p>I wanted to load test an application but there is a login page with two pages. The app is not signed in, although the username ... |
71,120,476 | Flutter - Restart countdown timer<p>I'm trying to restart the countdown timer when I click on the resend code. The package I'm using is <a href="https://pub.dev/packages/timer_count_down" rel="nofollow noreferrer">timer_count_down</a>.</p>
<p>I've tried adding:</p>
<pre><code> onTap: () {
_controller.restart();
... | <p>I've been able to reproduce your issue both by using your provided code and the example code of the package (provided by the project) <a href="https://github.com/DizoftTeam/simple_count_down/blob/master/example/lib/main.dart" rel="nofollow noreferrer">github.com/DizoftTeam/simple_count_down/blob/master/example/lib/m... | Flutter - Restart countdown timer | flutter|dart | -1 | 276 | 1 | 71,124,598 | 71,124,598 | 1 | true | 2022-02-15T02:30:13.210Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Flutter - Restart countdown timer<p>I'm trying to restart the countdown timer when I click on the resend code. The package I'm using is <a href="https://pub.... |
71,130,997 | How to convert a date string zone oriented and hour string into datetime<p>I have two strings one: <code>date='2021-12-30T23:00Z'</code> where Z means UTC timezone and 23:00 means hour. I also have an hour string <code>hour='3'</code>. What I want is to convert date to datetime object and add this hour string to date a... | <p>Use <code>strftime</code> with their format.</p>
<pre><code>from datetime import datetime, timedelta
date='2021-12-30T23:00Z'
date = datetime.strptime(date, '%Y-%m-%dT%H:%MZ')
new_date = date + timedelta(hours=3)
new_date = new_date.strftime('%Y-%m-%dT%H:%MZ')
print(new_date)
</code></pre>
<p>Output:</p>
<blockquot... | How to convert a date string zone oriented and hour string into datetime | python|date|datetime | -1 | 43 | 2 | 71,131,184 | 71,131,184 | 1 | true | 2022-02-15T17:41:39.667Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to convert a date string zone oriented and hour string into datetime<p>I have two strings one: <code>date='2021-12-30T23:00Z'</code> where Z means UTC ti... |
71,136,146 | pyspark get different varchar printSchema()<p>From spark dataframe when I run <code>df.printSchema()</code> all varchar(1), varchar(10), etc... becomes <code>string</code> Is there a way to differentiate varchars?</p>
<p>Doesn't have to be in pyspark. method to do it in spark sql is welcome as well.</p> | <p><code>VarcharType(length)</code> can only be used in table schema, not functions/operators. This means you can use it in create table sql, but not dataFrame schema.</p> | pyspark get different varchar printSchema() | sql|apache-spark|pyspark | -1 | 41 | 1 | 71,136,485 | 71,136,485 | 1 | true | 2022-02-16T03:45:36.950Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
pyspark get different varchar printSchema()<p>From spark dataframe when I run <code>df.printSchema()</code> all varchar(1), varchar(10), etc... becomes <code... |
71,138,598 | Wrong order of redo and undo strokes?<p>I want to implement undo and redo of inkcanvas strokes.</p>
<p>I want to implement redo and undo that can operate multiple times in a row.</p>
<p>I don't know where is the problem with my code.
Please help me.</p>
<p>My code is as follows:</p>
<p>xaml:</p>
<pre><code><Grid>... | <p>In your redo Method you do</p>
<pre><code> DoStroke dos = UndoStrokes.Pop();
if (dos.ActionFlag.Equals("ADD"))
{
inkCanvas.Strokes.Add(dos.Stroke);
}
else
{
inkCanvas.Strokes.Remove(dos.Stroke);
}
</code></pre>
<p>You should probabl... | Wrong order of redo and undo strokes? | c#|wpf|inkcanvas | -1 | 26 | 1 | 71,138,668 | 71,138,668 | 1 | true | 2022-02-16T08:44:10.060Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Wrong order of redo and undo strokes?<p>I want to implement undo and redo of inkcanvas strokes.</p>
<p>I want to implement redo and undo that can operate mul... |
71,139,280 | Django-python coding explanation<p>What is static method and how can we explain the below code ?</p>
<pre><code> @staticmethod
def get_model(**kwargs):
try:
return Model.objects.get(**kwargs)
except Model.DoesNotExist:
return
</code></pre> | <p>In short and maybe oversimplified: <code>staticmethod</code> doesn't require object of a class to run. This also means that you don't need <code>self</code> argument.</p>
<p>About the code:
This method is attempting to return single (.get()) instance of a Model that match with parameters specified in kwargs.</p>
<p>... | Django-python coding explanation | python|django|django-models|django-rest-framework | -1 | 31 | 2 | 71,139,754 | 71,139,754 | 1 | true | 2022-02-16T09:33:17.560Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Django-python coding explanation<p>What is static method and how can we explain the below code ?</p>
<pre><code> @staticmethod
def get_model(**kwargs):
... |
71,141,492 | How to add daySuffix to day using dateformatter in Swift<p>I am getting daySuffix with below code</p>
<pre><code>func daySuffix(from date: Date) -> String {
let calendar = Calendar.current
let dayOfMonth = calendar.component(.day, from: date)
switch dayOfMonth {
case 1, 21, 31: return "st"
case 2, 22: retu... | <p>When using date formatter all characters within <code>''</code> will be ignored and kept unformatted. So you simply need to do</p>
<pre><code>dateFormatter.dateFormat = "dd'\(daySuffix(from: date1))' MMMM, yyyy"
</code></pre>
<p>or does this not work for you?</p> | How to add daySuffix to day using dateformatter in Swift | ios|swift|date-format|suffix | -1 | 27 | 1 | 71,141,644 | 71,141,644 | 1 | true | 2022-02-16T12:01:49.367Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add daySuffix to day using dateformatter in Swift<p>I am getting daySuffix with below code</p>
<pre><code>func daySuffix(from date: Date) -> String... |
71,146,697 | Lambda getResult()<p>I came across the following bit of code online which I can't figure it out:</p>
<pre class="lang-java prettyprint-override"><code>mFoo.bar(future -> {
Bundle result = future.getResult();
boolean success = result.getBoolean(Foo.KEY_BOOLEAN_RESULT);
if (success) {
showToast(&qu... | <p>You can tell the type of 'future' from the specification of 'bar()'. Presumably that type has a 'getResult()' that returns a 'Bundle'. What does the documentation say></p>
<p>In general, a 'future' represents the eventual result of an asynchronous computation. For likely-similar functionality, see <a href="http... | Lambda getResult() | java|android | -1 | 40 | 1 | 71,146,918 | 71,146,918 | 1 | true | 2022-02-16T17:39:35.680Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Lambda getResult()<p>I came across the following bit of code online which I can't figure it out:</p>
<pre class="lang-java prettyprint-override"><code>mFoo.b... |
71,148,519 | Spring Boot validator does`t work properly<p>I have encountered such a problem that the validator does not see the data that I transmit in the body.</p>
<pre><code>WARN 4088 --- [io-28852-exec-1] .w.s.m.s.DefaultHandlerExceptionResolver : Resolved [org.springframework.web.bind.MethodArgumentNotValidException: Validatio... | <p>You have both <code>@JsonIgnore</code> and <code>@NotEmpty</code> on the field <code>password</code>. The first annotation will tell spring to ignore the value for the field password, thus <code>password</code> will always remain <code>null</code>. This will cause the <code>@NotEmpty</code> validation rule to always... | Spring Boot validator does`t work properly | java|spring-boot | -1 | 785 | 3 | 71,148,589 | 71,148,589 | 1 | true | 2022-02-16T19:59:07.847Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Spring Boot validator does`t work properly<p>I have encountered such a problem that the validator does not see the data that I transmit in the body.</p>
<pre... |
71,151,261 | Python - Different result from while loop than when in a user defined function<p>I am trying to create a code that returns a approximation of pi given n iterations that the user will give. The higher n the more accurate.</p>
<p>I created a while loop to do this, and it works fine:</p>
<pre><code>import math
x = 1
k = ... | <p>You have your <strong>return</strong> inside the loop, hence the block inside the while is executed only once and the rest of approximations are never calculated, put your return out of your cycle:</p>
<pre class="lang-py prettyprint-override"><code>while x <= n:
k=k+(1/x**2) # summation of 1/k**2 for every n... | Python - Different result from while loop than when in a user defined function | python|while-loop|user-defined-functions | -1 | 22 | 1 | 71,151,301 | 71,151,301 | 1 | true | 2022-02-17T01:10:27.830Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Python - Different result from while loop than when in a user defined function<p>I am trying to create a code that returns a approximation of pi given n iter... |
71,152,835 | I need to create a new dataframe as below in pysaprk from given input dataset<p>persons who has same salary should come in same record and their names should be separated by ",".</p>
<p>input Dataset :</p>
<p><a href="https://i.stack.imgur.com/0Np6G.png" rel="nofollow noreferrer"><img src="https://i.stack.img... | <p>You can achieve this as below -</p>
<p>Apply a <code>groupBy</code> on <code>Salary</code> and use - <a href="https://spark.apache.org/docs/latest/api/python/reference/api/pyspark.sql.functions.collect_list.html" rel="nofollow noreferrer">collect_list</a> to club all the <code>Name</code> inside an <code>ArrayType()... | I need to create a new dataframe as below in pysaprk from given input dataset | pyspark|apache-spark-sql | -1 | 30 | 1 | 71,153,743 | 71,153,743 | 1 | true | 2022-02-17T05:15:31.803Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I need to create a new dataframe as below in pysaprk from given input dataset<p>persons who has same salary should come in same record and their names should... |
71,155,587 | Call a function from dictionary by outputting numbers as strings in quotes<p>I have a dictionary that I want to use to call a function. My problem is, that the input needed for the function must be in quotes. My dict is like this:</p>
<pre><code>dict = {
'test': [10, 14, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, ... | <p>If you can, you probably should just change <code>testfunction</code>.</p>
<p>If that's impossible, you can use <code>list(str(n) for n in dict["test"])</code>, which transforms the given dictionary into a list of strings, and pass it as the argument to <code>testfunction</code>.</p> | Call a function from dictionary by outputting numbers as strings in quotes | python|string|function|dictionary | -1 | 25 | 1 | 71,155,626 | 71,155,626 | 1 | true | 2022-02-17T09:36:18.153Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Call a function from dictionary by outputting numbers as strings in quotes<p>I have a dictionary that I want to use to call a function. My problem is, that t... |
71,156,773 | Twitter Boostrap col exceeding container area<p>Hi I got 2 small problems</p>
<ul>
<li>my col class is exceeding the container area = <a href="https://i.imgur.com/Ee1VlqL.jpg" rel="nofollow noreferrer">https://i.imgur.com/Ee1VlqL.jpg</a></li>
<li>also I need a space between the 2 divs = <a href="https://i.imgur.com/05M... | <p>You don't have to override col-sm class. Instead, try something like this. Pay attention to the new class called border_div:</p>
<pre><code><html>
<head>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity=" sha384... | Twitter Boostrap col exceeding container area | html|css|twitter-bootstrap|bootstrap-5 | -1 | 36 | 2 | 71,158,001 | 71,158,001 | 1 | true | 2022-02-17T10:53:40.593Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Twitter Boostrap col exceeding container area<p>Hi I got 2 small problems</p>
<ul>
<li>my col class is exceeding the container area = <a href="https://i.imgu... |
71,157,975 | Edit lineTo points (in canvas)<p>I want to move <code>lineTo</code> points.<br />
How to do it?<br />
I'm new to Canvas.<br />
I'll give an example with <code>Path</code>.</p>
<p>This is my example:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-... | <p>Well, <code>canvas</code> as the name suggests, is a canvas (<em>just like in paintings</em>). You can draw on it, but you cannot move things on it as it is not "dynamic".</p>
<p>What you can do, though, is clear it and then draw on top at a different location.</p>
<p><div class="snippet" data-lang="js" da... | Edit lineTo points (in canvas) | javascript|html|html5-canvas | -1 | 23 | 1 | 71,158,125 | 71,158,125 | 1 | true | 2022-02-17T12:15:45.090Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Edit lineTo points (in canvas)<p>I want to move <code>lineTo</code> points.<br />
How to do it?<br />
I'm new to Canvas.<br />
I'll give an example with <cod... |
71,158,432 | SQLite3 SUM by date<p>I am using SQLite3 with Python, and I have some data that looks roughly similar to this:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th style="text-align: center;">Date</th>
<th style="text-align: center;">Parent ID</th>
<th style="text-align: center;">Child ID</th>
<... | <p><code>group by Date, ParentID</code> seems to work fine:</p>
<pre><code>select Date, ParentID, sum(Points) as Points
from table_name
group by Date, ParentID;
</code></pre>
<p><a href="https://dbfiddle.uk/?rdbms=sqlite_3.27&fiddle=ec465fde0e9f253d69266ecdb723faf3" rel="nofollow noreferrer">Fiddle</a></p>
<p>To cr... | SQLite3 SUM by date | python|sql|database|sqlite | -1 | 37 | 1 | 71,158,508 | 71,158,508 | 1 | true | 2022-02-17T12:47:22.813Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SQLite3 SUM by date<p>I am using SQLite3 with Python, and I have some data that looks roughly similar to this:</p>
<div class="s-table-container">
<table cla... |
71,159,092 | How does Keras layout works in Tensorflow<p>I'm testing Tensorflow but I can't figure out how the models are structured. For example, in the official documentation there are the following indications :</p>
<pre><code>A Sequential model is appropriate for a plain stack of layers where each layer has exactly one input te... | <p>It means that it accepts only one type of data (all values numeric or all categorical) because in Sequential model all input values go thru all layers sequentialy.</p>
<p>I prefere documentation in keras.io
<a href="https://keras.io/api/models/sequential/#sequential-class" rel="nofollow noreferrer">https://keras.io/... | How does Keras layout works in Tensorflow | tensorflow|keras | -1 | 36 | 1 | 71,159,315 | 71,159,315 | 1 | true | 2022-02-17T13:31:50.807Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How does Keras layout works in Tensorflow<p>I'm testing Tensorflow but I can't figure out how the models are structured. For example, in the official documen... |
71,159,312 | Deploy -> update -> deploy routine in cdk<p>For example I have these two lambda in <code>CdkStBaseStack</code></p>
<p>It can be deployed by <code>cdk deploy</code> at first.</p>
<p>Hoever later,when I updated the code in <code>resizer-sam/resizer</code>.</p>
<p>So, I want to deploy new version of <code>ResizerLambda</c... | <p>Assuming I understood the question correctly, doing a simple <code>cdk deploy</code> would bundle the new code and update your function accordingly.</p> | Deploy -> update -> deploy routine in cdk | amazon-web-services|aws-cdk | -1 | 40 | 1 | 71,161,833 | 71,161,833 | 1 | true | 2022-02-17T13:45:28.647Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Deploy -> update -> deploy routine in cdk<p>For example I have these two lambda in <code>CdkStBaseStack</code></p>
<p>It can be deployed by <code>cdk deploy<... |
71,161,471 | how to close a connection to a database from a response of a fetch API?<p>I have a file where I setup a connection to Mysql:</p>
<pre><code>class Connection extends Mysqli {
function __construct() {
parent::__construct('localhost','root','','prueba');
$this->set_charset('utf8');
$this->... | <p>It doesn't work like that. JavaScript is executed on the client-side (in the web browser) and PHP on the server-side. Every time you make a request to the server, the PHP script is executed from scratch. The connection is established on every request and closed when the request completes.</p>
<p>You can't close mysq... | how to close a connection to a database from a response of a fetch API? | javascript|php|mysqli|database-connection | -1 | 260 | 1 | 71,164,727 | 71,164,727 | 1 | true | 2022-02-17T16:01:39.697Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to close a connection to a database from a response of a fetch API?<p>I have a file where I setup a connection to Mysql:</p>
<pre><code>class Connection ... |
71,164,787 | How to get ForestTrustDomainInformation for a domain using Active Directory C# API<p>I am interested in <a href="https://docs.microsoft.com/en-us/dotnet/api/system.directoryservices.activedirectory.foresttrustdomaininformation?view=dotnet-plat-ext-6.0" rel="nofollow noreferrer">ForestTrustDomainInformation</a> for a do... | <p>It's not used with a <code>Domain</code> object, but from a <code>Forest</code> object, since it contains information for a trust between forests.</p>
<p>Assuming you have a <a href="https://docs.microsoft.com/en-us/dotnet/api/system.directoryservices.activedirectory.forest" rel="nofollow noreferrer"><code>Forest</c... | How to get ForestTrustDomainInformation for a domain using Active Directory C# API | c#|.net|active-directory | -1 | 41 | 1 | 71,164,866 | 71,164,866 | 1 | true | 2022-02-17T20:10:54.267Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to get ForestTrustDomainInformation for a domain using Active Directory C# API<p>I am interested in <a href="https://docs.microsoft.com/en-us/dotnet/api/... |
71,187,643 | Can't insert data in the same previous form - I lose data when I create a new form<p>My problem is that when I choose a row in my datagridview, it opens a new form, not the previous one.</p>
<p>Here is my code:</p>
<p>Button: "choix de l'article" in "Form1" : f2 to call form2</p>
<pre><code>public p... | <p>You create a new form each time, when you need to access the existing one.</p>
<p>It is a bit like buying a new car each time you go to work, when instead you should just keep the keys and use the same car again.</p>
<p>So you need to change your 2nd form to accept a reference to your first when when you create it. ... | Can't insert data in the same previous form - I lose data when I create a new form | c#|winforms | -1 | 31 | 1 | 71,187,850 | 71,187,850 | 1 | true | 2022-02-19T17:54:01.463Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Can't insert data in the same previous form - I lose data when I create a new form<p>My problem is that when I choose a row in my datagridview, it opens a ne... |
71,189,517 | mysql, cant group by without ruining my original code(inline view)<pre><code>select ename as Name, sal as Salary, sal/sum(sal)*100 from stud_v22_lykkeboeale.emp
</code></pre>
<p>i have this code, but when i do group by sal, it converts from this:</p>
<pre><code>| Name | Salary | sal/sum(sal)*100 |
|------+--------+---... | <p>Use window SUM(), not aggregate one:</p>
<pre class="lang-sql prettyprint-override"><code>SELECT Name, Salary, 100 * Salary / SUM(Salary) OVER () percent
FROM test
ORDER BY Salary, Name
</code></pre>
<p><a href="https://dbfiddle.uk/?rdbms=mysql_8.0&fiddle=99f39cbd06734643a64578aaccd36533" rel="nofollow noreferre... | mysql, cant group by without ruining my original code(inline view) | mysql | -1 | 28 | 1 | 71,189,618 | 71,189,618 | 1 | true | 2022-02-19T21:52:00.043Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
mysql, cant group by without ruining my original code(inline view)<pre><code>select ename as Name, sal as Salary, sal/sum(sal)*100 from stud_v22_lykkeboeale.... |
71,189,411 | Can I see implementation of UDF function in Spark SQL?<p>As I discovered Spark SQL does not have hashing functions. In order to select specific hashed data I need to use custom/UDF function like this</p>
<pre><code> sparkSession.udf.register("hashFuncWithSecret", (s: String) => myHashFunction(s, "m... | <p>It will not be visible from other Spark session. Farthest you can get is:</p>
<pre><code>scala> spark.catalog.listFunctions.show(false)
+-----+--------+-----------+-----------------------------------------------------+-----------+
|name |database|description|className |i... | Can I see implementation of UDF function in Spark SQL? | apache-spark|security|apache-spark-sql | -1 | 37 | 1 | 71,190,247 | 71,190,247 | 1 | true | 2022-02-19T21:37:50.777Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Can I see implementation of UDF function in Spark SQL?<p>As I discovered Spark SQL does not have hashing functions. In order to select specific hashed data I... |
71,189,655 | PyAutoGui locateOnScreen Loop<p>I've been trying to create a loop where it looks for an image, and if not found scrolls once then tries again until it finds it. Problem is, when it finds it, it doesn't break. I can't figure out why it isnt breaking. Its returns none each scroll, until it finds the image and it returns ... | <p>You're never changing the value of the <code>false</code> variable, so it always remains <code>None</code>. Also, you're playing with fire by using <code>false</code> and <code>none</code> as variable names.</p>
<p>This might work a little better:</p>
<pre><code>loc = None
while loc is None:
try:
loc = p... | PyAutoGui locateOnScreen Loop | python|pyautogui | -1 | 260 | 1 | 71,190,597 | 71,190,597 | 1 | true | 2022-02-19T22:14:02.890Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
PyAutoGui locateOnScreen Loop<p>I've been trying to create a loop where it looks for an image, and if not found scrolls once then tries again until it finds ... |
71,194,087 | Problem when Fetching data from MySQL database to html drop-down list<p>I have a country table with 2 columns (id and country name) and I'm using the technique mentioned in the answer to the <a href="https://stackoverflow.com/questions/37077152/fetching-data-from-mysql-database-to-html-drop-down-list">Fetching data fro... | <pre><code>Remove <select name="select1">
and close option tag properly </option>
</code></pre> | Problem when Fetching data from MySQL database to html drop-down list | php|html|mysql | -1 | 22 | 1 | 71,194,410 | 71,194,410 | 1 | true | 2022-02-20T11:46:09.280Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Problem when Fetching data from MySQL database to html drop-down list<p>I have a country table with 2 columns (id and country name) and I'm using the techniq... |
71,194,975 | How to save Jquery click event to local storage to hide css for a specific period<p>I am not good with Javascript and would appreciate any help here.
I have a written a css that display announcement when webpage loads up with a close button to hide the entire css and its contents using Jquery animate.</p>
<p>I would li... | <p>On <code>close click</code>, you can set the time until it should be hidden to the <code>localStorage</code>.
In this example it's basically <code>now</code> plus 10 seconds (adjust how you need it).</p>
<p>Then <code>setInterval</code> to periodically check if that time has been reached or not.</p>
<p>The same on <... | How to save Jquery click event to local storage to hide css for a specific period | javascript|jquery | -1 | 24 | 1 | 71,195,650 | 71,195,650 | 1 | true | 2022-02-20T13:40:33.930Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to save Jquery click event to local storage to hide css for a specific period<p>I am not good with Javascript and would appreciate any help here.
I have ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.