date
stringlengths
10
10
nb_tokens
int64
60
629k
text_size
int64
234
1.02M
content
stringlengths
234
1.02M
2018/03/06
932
3,717
<issue_start>username_0: I'm new to C# and I'm relatively new to abstract classes and inheritance and I'm having troubles understanding how to use them. I have this abstract enumeration class: ``` public abstract class Enumeration : IComparable { public uint Id { get; private set; } public string Name { get; p...
2018/03/06
1,025
4,045
<issue_start>username_0: This is my image uploader: ![My Image Uploader LINK](https://i.stack.imgur.com/6Zkv7.png) **My Code for adding an image which works perfect:** ``` jQuery(function($){ // Set all variables to be used in scope var frame, selections, attachment, metaBox = $('#gallery-meta-box.pos...
2018/03/06
466
1,706
<issue_start>username_0: I've got a problem whereby I've created an application where the user enters text into various text boxes. They then click a button which outputs it all into a text log file in a specific format. I create a string which I output to a file and that string is compiled from various pieces of text...
2018/03/06
1,406
4,224
<issue_start>username_0: I'm relatively new to Python, and am encountering some issues in writing a piece of code that generates and then solves a system of differential equations. My approach to doing this was to create a set of variables and coefficients, *(x0, x1, ..., xn)* and *(c0, c1 ,..., cn)* repsectively, in...
2018/03/06
789
1,716
<issue_start>username_0: I have a table of students with their scores listed by `Submitdate`. I'm trying to calculate the SUM, TOTAL, then AVERAGE of each student. Here is my table with data: ``` StudentsTbl ------------- ID G1 G2 Submitdate ------------------- 01 8 9 2017-11-06 01 9 10 2017-11-18 01 7 8 201...
2018/03/06
393
1,333
<issue_start>username_0: For example string.find not work correct: ``` print ( string.match("Test/(", "Test/(") ) ``` second argument is submitted as regexp, not simple string.<issue_comment>username_1: Is this what you're looking for? > > `string.sub(s, i [, j])s:sub(i [,j])` > > > Return a substring of the str...
2018/03/06
998
3,376
<issue_start>username_0: I have been using ngrok with ASP.NET 4.X without encountering any problems. Unfortunately, when I try to forward app build in ASP.NET Core 2 I run into a problem that I can't solve. I tried following combinations of commands to start ngrok: > > ngrok http 44374-host-header="localhost:44374"...
2018/03/06
809
2,855
<issue_start>username_0: I am running Node Application in cluster mode on AWS ec2 instance with 4 CPUs and 7.5 GB of RAM. I would like to monitor CPU and memory for my application. I am more interested in seeing **how is CPU and memory used for each(4 processes) workers**. How can I do this? Any tools I can use to acco...
2018/03/06
3,239
14,696
<issue_start>username_0: My MVC webapp allows users to add and delete images. The UI calls `ImageService.SaveImage(...)` in my business layer which internally uses a flag that tells the method to save to either Azure or the file system. I might eventually add S3 to I figure an interface here would work great. This is...
2018/03/06
3,019
13,329
<issue_start>username_0: So, via the anaconda prompt I created an environment and then installed numpy ``` conda -n CT_Bioinformatics python=3.6 conda install numpy ``` And it is installed Then on VSCode (where python interpreter is installed) I changed the interpreter to the one in the Enviroment's folder and it di...
2018/03/06
1,125
3,972
<issue_start>username_0: I just built my first `random forest classifier` today and I am trying to improve its performance. I was reading about how `cross-validation` is important to avoid `overfitting` of data and hence obtain better results. I implemented `StratifiedKFold` using `sklearn`, however, surprisingly this ...
2018/03/06
959
3,457
<issue_start>username_0: According to [the documentation](https://symfony.com/doc/current/console.html#executing-the-command), a command class must extend Command or ContainerAwareCommand to be automatically discovered and registered (provided its bundle is registered in the Kernel, of course). Since Symfony 4+, this ...
2018/03/06
606
1,935
<issue_start>username_0: I wanted to use the approach given in this answer: <https://stackoverflow.com/a/5419388/2050788>, but apparently I'm missing something, as cout does not wind up being redirected. Can someone explain what I'm missing? Here's a minimal compileable example: ``` #include #include #include str...
2018/03/06
1,525
4,083
<issue_start>username_0: How can i pull the "Toppings" Values from my JSON string into my list items? Thanks for your help! ``` Toppings -------- * JSON String Value * JSON String Value * JSON String Value * JSON String Value var myObj ={"menu": {"slice of pizza": "2.00", "toppings": {"pepperoni": ".25","meatballs"...
2018/03/06
515
1,882
<issue_start>username_0: Not sure if this is even possible. But what I want is to change this line of code inside the dockerfile ``` RUN $(npm bin)/ng build --prod --env=prod ``` to ``` RUN $(npm bin)/ng build --prod --env=test ``` Or better how do I make something like this work in gitbal-ci.yml file: ``` # Pro...
2018/03/06
955
3,439
<issue_start>username_0: Very new to coding here, but I am coding a web app, and I want to have two buttons at the top of the page. one to login/create an account, and another to add a review of the page. I added the first button and got it to display a modal when it was pressed, this all worked fine. I then tried to a...
2018/03/06
554
1,986
<issue_start>username_0: Dear stackoverflow masterminds, I'm new to Angular 2 and currently working on my first application. In short i want to show a sentence on screen with a timer. When this timer hits 0, i want it to reset and show the next sentence. I managed to create a timer with a variable i can use for an if-...
2018/03/06
1,662
4,401
<issue_start>username_0: I'm working on the following code: ``` mylist = [1,2,3,4,5,6,7,8,9,10.....] for x in range(0, len(mylist), 3): value = mylist[x:x + 3] print(value) ``` Basically, I'm taking 3 items in `mylist` at a time, the code is bigger than that, but I'm doing a lot of things with them returning...
2018/03/06
742
2,725
<issue_start>username_0: I created 2 self signed certificates: 1. A root certificate: `MyRootCA` self-signed 2. A code signing certificate: `MyCodeSign` signed by `MyRootCA` Now I add `MyRootCA` to the *Trusted Publishers* in Excel's Trust Center and sign my VBA code with `MyCodeSign` (which is not added to the Trust...
2018/03/06
633
1,919
<issue_start>username_0: So I have a date which is in this format. My goal is to add 7 days to this string `startdate` and post it into a database as a string. However, I have to convert it to datetime to allow me to add days to it. I am reading `startdate` from a database but this is what it looks like. ``` string s...
2018/03/06
491
1,826
<issue_start>username_0: I have the following code in my pie chart options in order to change the mouse cursor to pointer on hover: ``` hover: { onHover: (e, el) => { const section = el[0]; const currentStyle = e.target.style; currentStyle.cursor = section ? 'pointer' : 'normal'; } ...
2018/03/06
1,934
6,452
<issue_start>username_0: I have two query to combine two results into one. However; my challenge is to get the second query look into the first query if it doesn't exist in the first query. I changed my post to the actual query ``` SELECT Name.CO_ID, Name.FULL_NAME, Name.ID, rpt.date AS StartDate, ...
2018/03/06
281
834
<issue_start>username_0: i have a logic app that needs an input of date as its variable. I see there is something like day of month from which i can get day but not month and year. Any idea how i can concatenate date in the above format?<issue_comment>username_1: You can use formatDateTime function: > > Returns a str...
2018/03/06
1,076
4,068
<issue_start>username_0: There is a form. The submit button does not apply to ActiveForm with `id = "modal-btn-register-request"`. In JQuery, by clicking on this button I call `$("#modal-btn-register-request").submit()` and the form has been validated or not sent to the action. How can I validate before clicking the bu...
2018/03/06
792
2,485
<issue_start>username_0: I tried a lot of things I read on documentations or tutorials... But I still can't cross-compile Qt with the MySQL library driver. Story begins: I have to cross-compile Qt from Linux to Windows (32bits) using MinGW (`i686-w64-mingw32-` prefix to be precise). I downloaded `qtbase-opensource-src...
2018/03/06
4,561
6,758
<issue_start>username_0: I have a vector of letters or symbols, say bases=c('A','T','G','C'), is there a shorter and more efficient way(an existing function)to generate all possible k-mers for a given k, other than using nested for loop or sapply?<issue_comment>username_1: Use the function `permutations` from `gtools` ...
2018/03/06
499
1,885
<issue_start>username_0: I have a Python script that contains the following modules: ``` from tkinter import * from tkinter import ttk from tkinter import filedialog ``` When I run the code in IDLE by pressing F5 the script runs fine and starts my app. However, when I go to the command prompt and type ``` python ...
2018/03/06
493
1,437
<issue_start>username_0: I want to sort an array so that a specific array with a specific value is shown as the first in the array. The array I have: ``` array = [ [0] => [ 'id' => 123, 'name' => 'Random' ], [1] => [ 'id' => 156, 'name' => 'keybo...
2018/03/06
786
2,819
<issue_start>username_0: ``` Fiction NonFiction Fiction Fantasy ``` <http://www.protractortest.org/#/api?view=ElementArrayFinder.prototype.filter> If I use ``` element.all(locator).filter(filterFn) ``` the text returned is empty. How can I go to parent element to get the text? ``` label[class="radio...
2018/03/06
659
2,853
<issue_start>username_0: I am a total noob developing iOS applications and I'm working in one right now. I have set up my storyboard with a `HomeViewController` (main) and inside this, a container view, with another view controller embeded. This child view controller is outside the bounds of the view, and when a click...
2018/03/06
939
3,220
<issue_start>username_0: I found legacy source code and here excerpt - ``` TMemoryStream *DFile = new TMemoryStream; TFileStream*BFile = new TFileStream; ``` Here are the some official documented data for above classes: * [TMemoryStream Wiki](http://docwiki.embarcadero.com/Libraries/Tokyo/en/System.Classes.TMemory...
2018/03/06
1,116
3,065
<issue_start>username_0: I want to know how can i plot a circle with Basemap using latitude and longitude. ``` import matplotlib.pyplot as plt fig,ax = plt.subplots() ax.axis([0,10,0,10]) circle1 = plt.Circle((5, 5), 2, color='black',fill=False) x = ax.add_artist(circle1) plt.show() ``` [![enter image description h...
2018/03/06
940
2,622
<issue_start>username_0: I need to make new URL depending on input text ``` Name: check tracking ``` And DHL making it adding code to URL for example: `https://nolp.dhl.de/nextt-online-public/en/search?piececode=` plus tracking code here. The demo URL is this: `https://nolp.dhl.de/nextt-online-public/en/searc...
2018/03/06
843
2,409
<issue_start>username_0: I have spreadsheet similar to this: [![enter image description here](https://i.stack.imgur.com/4Igff.png)](https://i.stack.imgur.com/4Igff.png) I'd like to remove all duplicates of row based on the first column data. So from this screenshot row, 1 and 2 would be kept, and row 2 would be rem...
2018/03/06
521
1,394
<issue_start>username_0: I want to write a regex that may contains alphabets or number or spaces between word and must be of length between 3 to 50 but not spaces on start and end of string. This is my regex: ``` /^[^-\s]([a-z0-9]|[a-z0-9\s-]){3,50}[^-\s]+$/i ``` Valid strings: ``` uma umair umair K ``` Invalid ...
2018/03/06
545
1,692
<issue_start>username_0: Hello i am new in Regex of the Notepad++ Replace Option i have alot of files that start with ``` #include ``` and i need to convert them to ``` #include "someheader.h" ``` without loosing the someheader.h i did try using this replace method: ``` #include ``` but it wont get the val...
2018/03/06
1,902
7,526
<issue_start>username_0: I have products defined by their Name and Location. Each product has a unique pair of Name/Location. I'm writing a view to be able to create a product and I would like to first check if it exists in DB. If yes then keep the ID somewhere to return it to my front app. If no then create it and ge...
2018/03/06
2,229
7,447
<issue_start>username_0: I have a slider whose ticks should should have the names of the year. Below code works, but the label of the ticks are not aligned properly. Each year number should be besides a tick. ``` class Slider(QWidget): def __init__(self, minimum, maximum, parent=None): super(Slider, self)....
2018/03/06
903
2,874
<issue_start>username_0: I have a kendo grid defined inside a razor view `(MVC4)`, and I also have dataSource event handler - onRequestStart like this: ``` function onRequestStart(e){ var gridId = e.sender... //the rest of the code } ``` What I am trying to do is to get `gridId` inside function without passin...
2018/03/06
516
1,662
<issue_start>username_0: I am trying to identify on which stored procedures a custom role has execute permission using a query. I tried using has\_perms\_by\_name, but I failed to understand and use it.<issue_comment>username_1: [this](http://sql-articles.com/scripts/script-to-retrieve-security-information-sql-server-2...
2018/03/06
621
2,361
<issue_start>username_0: I Successfully wrote VBA to scrape Data from a webpage. Since the Data updates regularly, I would like it to update in my Excel Document as well. The Data I'm getting is the different Odds from All BookMakers listed. I tried the .refreshperiod .refresh function for the Variable HTMLRow but ...
2018/03/06
669
2,581
<issue_start>username_0: Is it possible in [Siesta](https://github.com/bustoutsolutions/siesta) to use a cache policy like: * LocalOnly * NetworkFirst Where *LocalOnly* is getting the data from the local cache only, and *NetworkFirst* is getting the data from the network, and if it fails, retrieve from local cache.<i...
2018/03/06
786
3,084
<issue_start>username_0: Lets say I have a table (VersionTEMP) with the following 3 entries: ``` -------------------------------- | VersionName | VersionID | -------------------------------- | a-seattle | | | e-everett | | | k-kitsap | | ------------------------...
2018/03/06
766
2,522
<issue_start>username_0: I'm trying to record the attendance of each student, I was able to retrieve the value of the checkbox (Late, Excuse, Absent). Is there a way that I can get both the student ID and the attendance mark from the checkbox? I need to pair the student ID with his/her attendance mark. ```html php ...
2018/03/06
560
2,313
<issue_start>username_0: Is there any difference in execution between? ``` launch { function1() } fun function1(){ DoSomething... } ``` And ``` launch { function2() } suspend fun function2(){ DoSomething... } ```<issue_comment>username_1: Yes, there is. Semantically, a call to a suspending function ...
2018/03/06
586
2,504
<issue_start>username_0: I am new to Dlib and was looking through the exams that it comes with, I amd trying to build a car detector using an SVM and was wondering what the difference between a .svm file and a .dat file. I am asking this because the example projects are all using .dat files for object detection but wh...
2018/03/06
732
2,661
<issue_start>username_0: For my application the email field of a User should be required. That's not the case for the default User model. So I thought it would make sense to create a custom user model as described in the [docs](https://docs.djangoproject.com/en/2.0/topics/auth/customizing/#using-a-custom-user-model-whe...
2018/03/06
428
1,670
<issue_start>username_0: I have the following (simplified) kotlin code: ``` data class Event(val name: String, val venue: Venue?) data class Venue(val lat: Double, val lng: Double) ... return events .filter { it.venue != null } .map { doSomething(it.venue.lat, it.venue.lng) ``` The code doesn't co...
2018/03/06
1,757
5,652
<issue_start>username_0: I have a requirement to write a generic code that perform sorting on the `Seq[T]` objects. I know it **won't** be possible to perform sorting operation until we know the `base class` and its `attributes`. After taking a look into this [answer](https://stackoverflow.com/questions/23091076/scala-...
2018/03/06
402
1,390
<issue_start>username_0: How to update/replace the value from app.config for different environment using Teamcity? For Ex: Consider below URL is for one environment. add key="URL" value="https://www.google.co.uk" Now I want to update this value through Teamcity for different environment as: add key="URL" value="https...
2018/03/06
1,136
3,862
<issue_start>username_0: I have changed Kotlin version to 1.2.30. After the update I unable to run the project. I got the below error message. ``` Error:Execution failed for task ':app:compileDevDebugJavaWithJavac'. > app: Original kapt is deprecated. Please add "apply plugin: 'kotlin-kapt'" to your build.gradle. ```...
2018/03/06
596
2,274
<issue_start>username_0: I am trying to write a sub to delete all queries in a workbook. I have got the code below: ``` Dim CN As Variant Dim qTable As QueryTable For Each CN In ThisWorkbook.Connections CN.Delete Next CN For Each qTable In Sheets("Property Extract 1").QueryTables qTable.Delete Next qTable' ```...
2018/03/06
744
2,873
<issue_start>username_0: I need help on transforming the JSON to an user readable text. Sample JSON: ``` { "condition": "or", "rules": [{ "field": "X", "operator": "IN", "value": ["A", "B"] }, { "field": "Y", "operator": "IN", ...
2018/03/06
581
1,752
<issue_start>username_0: I have the scaling factors `sf=[0.5,0.75,0.85,1,1.25,1.5,1.75,2]`, and I want to calculate the coordinates of the point `e=[70, 140]` (blue line) by scaling relative to the `center_point=[89, 121]` (red point in the picture) in python. ``` scaled_point_x = e[0] * sf[0] scaled_point_y = e[1] *...
2018/03/06
744
2,383
<issue_start>username_0: Please help me understand why I'm receiving this error and what I can fix for the code to run properly. I believe it has something to do with the Graphs section. Thanks in advance! ``` Sub LocationAdjust() Dim Facility As String On Error GoTo Errorcatch Facility = "B1" If Fa...
2018/03/06
450
1,649
<issue_start>username_0: ``` import { Button, Form, FormGroup, Label, Input, FormText } from 'reactstrap'; export default class UserPicForm extends React.Component { constructor() { super(); // bindings this.handleSubmit = this.handleSubmit.bind(this); } handleSubmit(event) { event.preventDefa...
2018/03/06
496
1,921
<issue_start>username_0: I'm using fullcalendar with month, agendaWeek, and agendaDay(with resources) views and I'm facing some problems with Today button in agendaDay view. While Prev and Next buttons work as supposed, I need to click on Today button twice to trigger the click event, even though it only needs one clic...
2018/03/06
1,137
3,598
<issue_start>username_0: im trying to get json from openweathermap.com using volley i have this java code : ``` public void findWeather(int latitude,int longitude){ final Info info=new Info(); url="http://api.openweathermap.org/data/2.5/forecast?lat="+latitude+"&lon="+longitude+"&appid=9a40ef2a4c35689b29978...
2018/03/06
740
2,685
<issue_start>username_0: I want a sub form to appear based on what answer I choose in a select input. I can't understand why its not working. No error messages in console, but nothing happens. ```js document.getElementById('isAthlete').onchange = function(){ if(this.value == 'yes'){ document.getElementById('athle...
2018/03/06
421
1,728
<issue_start>username_0: I want to ping public dns and web servers in order to test and verify connectivity between our AWS instance and remote servers out of AWS instances but I couldn't find any resources about the resolution of my issue. ICMP Requests (outbound) on NACL and All ports in Security Group (outbound) of ...
2018/03/06
1,080
3,127
<issue_start>username_0: I am trying to emulate **Ubuntu Core for Raspberry Pi 3** using QEMU but it does not work. I found tutorials about emulating Raspbian using QEMU and tried to apply them to Ubuntu Core: * [RASPBERRY PI ON QEMU](https://azeria-labs.com/emulate-raspberry-pi-with-qemu/) * [Using QEMU to emulate...
2018/03/06
408
1,368
<issue_start>username_0: I hope you can help me with a very specific thing that I want to do in my python code. So, I want to create a concrete number of csv files, I mean, I want to create a csv file for each material in a storage. At this moment I have: ``` nMat = 2 for i in range(nMat): with open(infoVar[i]...
2018/03/06
947
3,103
<issue_start>username_0: I'm trying to append the contactTable with new rows for each ContactID and ContactName from my json response in a table. I am receiving data into the console but when I try to insert that data into my html document, I get a `undefined` value for each. html result ``` | | | | --- | --- | ...
2018/03/06
1,613
6,613
<issue_start>username_0: This is what the JSON structure looks likes. I have taken out personal information from the data. ``` { "Version": "1.0", "IsUpToDate": false, "LastModificationGUID": "{numbers}", "DisplayName": "DATE", "CreateDate": "DATE AND TIME", "ServerID": 0, "CreatorServerID...
2018/03/06
1,456
4,680
<issue_start>username_0: I would like to obtain the DDL of a table and create another one from it. Currently I have something like this: ``` v_stmt := 'select dbms_metadata.get_ddl(''TABLE'', ''' || original_table || ''') from dual'; execute immediate v_stmt into v_stmt ; v_stmt := REGEXP_REPLACE(v_stmt, '(' || ori...
2018/03/06
457
1,607
<issue_start>username_0: ``` $query='insert into shopping_tbl (itemcode,name)values ("'$num."/".$barcode.","."$name"'")'; ``` the itemcode wont be inserted because of the "/". however if i use "-" instead of "/" it will be inserted however i need to use "/" sample data: itemcode: 23/xxdd22, name: watchx<issue_commen...
2018/03/06
1,061
3,079
<issue_start>username_0: I am trying to run chainer with GPU on google colab. This requires cupy installed however I fail to install this properly as it cannot find the cuda environment in my colab vm. Error message as follows... > > Collecting cupy > Downloading cupy-2.4.0.tar.gz (1.7MB) > 100% |█████████████████...
2018/03/06
545
2,041
<issue_start>username_0: I have made a simple test fixture: ``` export interface ITest1 {} export interface ITest2 {} export interface ITestGeneric {} export function test() { let p: ITestGeneric = {} let q: ITestGeneric = p; } ``` I would expect the last line to fail, because in C# such incompatible type assignm...
2018/03/06
592
2,167
<issue_start>username_0: I'm trying to push the values in the input field to the firebase app. I have managed to fetch data from it but i can't seem to understand the submit function. I feel like i'm missing something really simple. When i try to use savePost it says it's not a function. ``` the action is: export ...
2018/03/06
1,422
6,422
<issue_start>username_0: I have issues implementing CloudTrail via Cloudformation, with a Incorrect S3 bucket policy is detected for bucket error being thrown when I try to launch the model. Here is the configuration from the BucketPolicy: ``` "LogBucketPolicy": { "Type": "AWS::S3::BucketPolicy", "Pro...
2018/03/06
1,252
3,367
<issue_start>username_0: I have a dataset consisting of student marks in 2 subjects and the result if the student is admitted in college or not. I need to perform a logistic regression on the data and find the optimum parameter θ to minimize the loss and predict the results for the test data. I am not trying to build a...
2018/03/06
1,058
2,876
<issue_start>username_0: I am creating a data format, which will be stored in a DS2431 1-wire EEPROM. One page will be using EPROM emulation mode (where data once written can only be modified by clearing bits). In this page I want to store a byte with an ID, which cannot be changed to another valid value (due to only a...
2018/03/06
1,748
5,517
<issue_start>username_0: I have a predefined character->type dictionary. For example, 'a' - is a lower\_case letter, 1 is a digit, ')' is a punctuation symbol etc. With the following script, I label all characters in a given string: ``` labels='' for ch in list(example): try: l = character_type_dict[ch] ...
2018/03/06
1,731
5,607
<issue_start>username_0: I have a logic app with a sql trigger that gets multiple rows. I need to split on the rows so that I have a better overview about the actions I do per row. Now I would like that the logic app is only working on one row at a time. What would be the best solution for that since `"operationOpti...
2018/03/06
425
1,373
<issue_start>username_0: I'm trying to match by regex in Ruby or in Javascript a string that contains non english characters. So is there a way to replace the string "täglichen" with the string "taglichen" ? I know that i can replace non english characters by options like: ``` /(?i)t[aä]glichen/ ``` But for this i ...
2018/03/06
787
2,995
<issue_start>username_0: I am currently trying to make a program that can read a .blend file. Well trying is the important part, since I am already stuck on reading the file block info. [Im gonna quickly explain my problem, please refer this page for context](https://wiki.blender.org/index.php/Dev:Source/Architecture/...
2018/03/06
563
1,985
<issue_start>username_0: How to convert a character column to date in R My column is in the format "20110314" (exclude ") where first 4 characters refer to year, next two to month and the last two to date.<issue_comment>username_1: Yup, that's painful. The solution is not to treat them as C++ at all. Instead, create yo...
2018/03/06
512
2,006
<issue_start>username_0: I have seen people instantiate objects in 2 different ways, which way is best and why? or is there even a difference? ``` class Entity { public: Entity(const std::string& name) : mName(name); ~Entity(); private: std::string mName; }; int main() { Entity ent("myname"); En...
2018/03/06
697
2,592
<issue_start>username_0: I am relative new at C++ and I have little problem. I have vector and in that vector are vectors with 3 integers. Inner vector represents like one person. 3 integers inside that inner vector represents distance from start, velocity and original index (because in input integers aren't sorted a...
2018/03/06
625
2,225
<issue_start>username_0: I have three users , when I click on next it has to load route for next user, SO I am adding one to id and passing to routerLink, bu somehow instead of adding it is concatenating the numbers, Below is the code ``` import { Component, OnInit, OnDestroy } from '@angular/core'; import { Activated...
2018/03/06
711
2,774
<issue_start>username_0: `OpenSsl` generates a private key in `DER` format with 118 bytes length. (`openssl ecparam -genkey -name secp256k1 and so on`). In android `KeyPairGenerator` initialized like: ``` KeyPairGenerator keyPairGenerator = KeyPairGenerator.getInstance("ECDSA", "SC"); ECGenParameterSpec ...
2018/03/06
1,514
5,445
<issue_start>username_0: I used Bitbucket to compare two branches. When I compared my `master` branch (as my source) to my `uat` branch (as my destination) and looked at the diff, I noticed that the list of files are totally different when I compared `uat` (as my source) to `master` (as my destination). There are a lot...
2018/03/06
1,127
2,499
<issue_start>username_0: I have the following matrix: ``` a = array([ [100. , 100., 100.], [175.2, 198., 32.], [ 38. , 82. , 38.], [155. , 32. , 23.], [ 38. , 67. , 30.]]) ``` How do I change the numbers in all rows, but except the last row into zero if a number of a row is not equal to 38 and 32...
2018/03/06
1,205
3,592
<issue_start>username_0: I'm trying to solve a problem called five\_sort that accepts an array of integers as the argument and places all the fives at the end of the array and leaves all of the other numbers unsorted. For example, `[1,2,5,3,2,5,5,7]` would be sorted as `[1,2,3,2,7,5,5,5]`.The rules for the problem stat...
2018/03/06
804
3,010
<issue_start>username_0: We are using **Lazy Loading** for **Router Modules**. ``` { path: 'users', loadChildren: 'app/users/users.module#UsersModule', }, ``` But when we **update version** of our app (upload new bundle to the server) it's always broken: old app (that user has already downloaded) tries t...
2018/03/06
463
1,682
<issue_start>username_0: Is there any way to disable all irq from Cortex M3 MCU except one ? My issue is that I have a system running several kinds of irq with various priority levels and I want to disable all irq except one in a particular state. I know I can disable all irq by using "\_\_disable\_irq()" instructio...
2018/03/06
753
3,022
<issue_start>username_0: In the method below, I have a two-dimensional array of characters called myarr and a string called code. I go through each character in code using the counter i, and look for a character in myarr that matches code[i]. When I find the character in myarr that matches code[i], I want to exit both ...
2018/03/06
287
1,111
<issue_start>username_0: I did set the necessary privileges for the app, and for some events it is working. For instance: `NSEvent.addGlobalMonitorForEvents(matching: .flagsChanged) { print("\($0)") }` works, but `NSEvent.addGlobalMonitorForEvents(matching: .keyDown) { print("\($0)") }` doesn't. So I am wonderi...
2018/03/06
537
1,825
<issue_start>username_0: I need help figuring out how to complete step #3.. please.. the textbook that I'm using doesn't explain the counting function very well, it just shows this "len" function the way I have it coded below, which is incorrect. 1. Add an input() statement at the start of the program. The input() sh...
2018/03/06
582
2,058
<issue_start>username_0: Here I want my code to let the user enter a game and then enter a rating, and the loop puts it in a dictionary but what I would like to do it sort the dictionary (games) by the ratings that the user input for the games ``` games = [] def gamef(): print("Here you will type your favorite gam...
2018/03/06
523
1,301
<issue_start>username_0: Suppose I have two arrays, `x` and `y`, where `y` is a subset of `x`: ``` x = [1, 2, 3, 4, 5, 6, 7, 8, 9] y = [3, 4, 7] ``` I want to return an array like: ``` ret = [False, False, True, True, False, False, True, False, False] ``` If `y` were just a single number it would be easy enough (...
2018/03/06
435
1,235
<issue_start>username_0: I have one Stored Procedure lets call it ABC, which generates a temporary table ##ref1. This procedure will execute only if the weekday is equal to a MONDAY. I have another Stored Procedure let call it XYZ, which generates an output table which a union of ##ref1 from ABC and similarly few oth...
2018/03/06
621
2,098
<issue_start>username_0: I am using two separate cookies in CakePHP to store two separate arrays: ``` $this->Cookie->write('first', $firstArray, true, '6 months'); $this->Cookie->write('second', $secondArray, true, '6 months'); ``` The way I access the arrays stored in my cookies is by using this: ``` $firstArray =...
2018/03/06
1,508
4,446
<issue_start>username_0: I am trying to dynamically get the last day of the prior month and pass it into a query. I tried the following idea, but it dind't work. ``` DECLARE @PrevMonthLastDay DATE=(SELECT CONVERT(CHAR(15),DATEADD(DD,-Day(GETDATE()),GETDATE()),106)) --PRINT @PrevMonthLastDay INSERT INTO [TBL_ParseRawDa...
2018/03/06
549
2,210
<issue_start>username_0: I am trying to built a concourse pipeline which is triggered by git, and then runs a script in that git repository. This is what I have so far: ```html resources: - name: component_structure_git type: git source: branch: master uri: <EMAIL>:foo/bar.git jobs: - name: compo...
2018/03/06
493
1,587
<issue_start>username_0: I am trying to write an npm module. However, the workflow is a little odd. I would like to just be able to execute my function after I make changes. This is my index.js file so far: ``` const _ = require("lodash"); exports.run = () => { const array = [1, 2, 3]; const double = _.map(array...
2018/03/06
962
2,659
<issue_start>username_0: I am trying to capture n consecutive capitalized words. My current code is ``` n=5 a='This is a Five Gram With Five Caps and it also contains a Two Gram' re.findall(' ([A-Z]+[a-z|A-Z]* ){n}',a) ``` Which returns the following: ``` ['Caps '] ``` It's identifying the fifth consecutive ca...
2018/03/06
516
1,631
<issue_start>username_0: I am trying to parse a hex value to decode a card The hex data I receive from the card is `f8b2d501f8ff12e0056281ed55` First I am converting this to an integer with parseInt() ``` var parseData = parseInt('f8b2d501f8ff12e0056281ed55', 16); ``` The value recieved is `1.970393014580087...
2018/03/06
1,118
2,124
<issue_start>username_0: i'm weak in regex, excuse me for asking this question i have sort of strings like these: ``` 4H71NP35P2","" 80844UNWR2","" 53UT5Z7E09","" 963ZF761A4","" 9U30538OX8","" F1CK67N510","" 308VWHR688","" 6I5E8XKL6H","" Y42WHYY997","" 3SF73CDEGX","" JGQB0X133N","" 5Y5Z956O45","" XKMXJJA822","" Y0ZO3N...
2018/03/06
1,805
4,646
<issue_start>username_0: I understand I can search for an ( a single item in an array) several different ways. Iterate with for loops, foreach, recursive structures etc, but I am not trying to do that as I am searching for multiple items at a time. For instance I may have an array of objects with this model: people:...