date
stringlengths
10
10
nb_tokens
int64
60
629k
text_size
int64
234
1.02M
content
stringlengths
234
1.02M
2018/03/08
613
1,729
<issue_start>username_0: I have the following array ``` a=[["name","age"], ["Raja","29"], ["Gop","30"] ["pal","21"] ] ``` And I need the following Hash ``` a=[{"name"=>"Raja","age"=>"29"},{"name"=>"Gop","age"=>"30"},{"name"=>"Gop","age"=>"30"},{"name"=>"pal","age"=>"21"}] ``` What it does ...
2018/03/08
389
1,012
<issue_start>username_0: I am using webhook to create bot for page. I got everything but not getting where to get Callback URL [![enter image description here](https://i.stack.imgur.com/6qvxt.jpg)](https://i.stack.imgur.com/6qvxt.jpg)<issue_comment>username_1: I would do something like this: ``` a = [['name', 'age'], ...
2018/03/08
515
1,999
<issue_start>username_0: What is the difference between End process and End process Tree in Task Manager in Windows.Is End process tree will kill all the child process under parent?<issue_comment>username_1: End Process: will end/kill/close the current application. End Process Tree: will end/kill/close the current app...
2018/03/08
5,178
14,438
<issue_start>username_0: I need to generate a graph like I have shown here [Single line with multiple colors over time](https://i.stack.imgur.com/nvzUE.jpg) The X axis will be time series . Can anyone suggest a JQuery plugin to generate such a graph ? Thanks<issue_comment>username_1: Try below chart and change as pe...
2018/03/08
1,912
3,800
<issue_start>username_0: I have a dashboard in Power BI that shows me all the runs that have failed from Logic Apps, incl their runID. Currently I need to copy and paste that runID into the Logic App Runs UI to filter and then click on it to see the Run detail and find out where it failed. When I click on a run, the ...
2018/03/08
1,133
3,538
<issue_start>username_0: I wrote a simple program. ``` class Sample: num =45 def __init__(self): print('Inside constructor') @classmethod def modifyUsingClassMethod(cls): cls.num = cls.num + 45 @staticmethod def modifyUsingStaticMethod(): Sample.num = Sample.num+5 s...
2018/03/08
528
1,783
<issue_start>username_0: While using the dependencies shows error on either auth or on database.how to resolve this??? ``` dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'com.android.support:appcompat-v7:26.1.0' implementation 'com.android.support.constraint:constraint-layout:1....
2018/03/08
737
2,774
<issue_start>username_0: I want to override html error page for 404 responses as an JSON response. When i use `@ControllerAdvice` without `@EnableWebMvc` it is not working. ``` @EnableWebMvc // if i remove this, it is not working @ControllerAdvice @Order(Ordered.HIGHEST_PRECEDENCE) public class GlobalControllerExcep...
2018/03/08
690
2,643
<issue_start>username_0: I am unable to focus on any `input` field inside **bootstrap carousel**. No matter how many times you click on it, the `input` field is not getting focused. I even tried giving `z-index` to the `input` field but it still doesn't get focused. You can check the error by running the ***snippet...
2018/03/08
1,400
5,062
<issue_start>username_0: I have applied the below settings in VS Code to get 4 spaces indentation. But always when I open a new file, it switches back to 2 in the right-bottom corner. If I click in the right-bottom corner and change the setting back to 4, VSCode will still change back to 2 and still apply it w...
2018/03/08
1,387
5,033
<issue_start>username_0: I am trying to install node.js and then check appium version using `appium -v` ``` import os,subprocess os.system('node.msi') os.system('exit') os.system('appium -v') ``` `node.msi` is a node file on my computer. when i do it through cmd, `appium -v` works if i do it in a new cmd, but it doe...
2018/03/08
1,154
4,379
<issue_start>username_0: Example of question: Is calculating 123 \* 456 faster than calculating 123456 \* 7890? Or is it the same speed? I'm wondering about 32 bit unsigned integers, but I won't ignore answers about other types (64 bit, signed, float, etc.). If it is different, what is the difference due to? Whether ...
2018/03/08
2,147
5,879
<issue_start>username_0: In this question I need some algorithmic or logical help from you guys. If this is possible in some ways... So I have to develop/write a function that receive a temperature value as an input (C° or F°), and return the specific color against the temperature exactly in this picture. For example...
2018/03/08
3,313
10,054
<issue_start>username_0: I have an `Attribute Table` ``` +-------------+--------------+----------------+-------------------+ | AttributeId | Attribute | AttributeLevel | ParentAttributeId | +-------------+--------------+----------------+-------------------+ | 1 | Ice Creams | 1 | NULL ...
2018/03/08
826
2,921
<issue_start>username_0: yii2 how to make a notification by e-mail to the user after changing his status?? Help me, Please! Model ``` class Applicants extends \yii\db\ActiveRecord { public $file; public static function tableName() { return 'applicants'; } public function rules() { ...
2018/03/08
1,311
4,336
<issue_start>username_0: I'm trying to show / hide part of a component based on the value in a drop down list. Before moving this part of my form, using a computed property worked just fine. However... I am using two way binding in my component and it seems that the computed value of the property I am using is updating...
2018/03/08
2,708
7,394
<issue_start>username_0: I m working on .net 4.6 in winforms (here code is from test console application) At one point I'm having a list of `DateTime` and I need to figure out if this list contains specific date or not. For that I m trying use `Any()` on the list. Even if the list does contain the desired date, `Any(...
2018/03/08
387
950
<issue_start>username_0: Epoch time with leading 3 zeros is returning an invalid year. ``` Time.at(1520486517000).to_datetime => Wed, 19 Apr 50152 19:20:00 +0530 ``` After removing ending 3 zeros, it's returning and valid time stamp. ``` Time.at(1520486517).utc.to_datetime => Thu, 08 Mar 2018 05:21:57 +0000 ```...
2018/03/08
256
984
<issue_start>username_0: Please tell me how to work with **PHP, HTML, CSS & JS** within same file **simultaneously**. I mean I do this most often, that the file is `*.php` extension but I have to write HTML, CSS, PHP, JS all in the same file. So that for each language **code hinting could work, it doesn't work**. I h...
2018/03/08
1,459
4,762
<issue_start>username_0: Is there a possibility to change the default color of a checked checkbox (mat-pseudo-checkbox-checked): ``` {{shoe}} ``` I have tried: ``` .mat-pseudo-checkbox-checked { background-color: #00f; } ``` but it has no impact.<issue_comment>username_1: I am not sure but you can try usin...
2018/03/08
826
3,265
<issue_start>username_0: I'd like to install a list of windows features, e.g. IIS-WebServerRole, saved in a packages.config using chocolatey. Listing available windows features gives me the ID's.... ```html choco list --source windowsFeatures Chocolatey v0.10.8 Deployment Image Servicing and Management tool Versio...
2018/03/08
259
971
<issue_start>username_0: <https://react.semantic-ui.com/modules/accordion> on their first example, I have a requirement where I need another icon instead of dropdown. I need to replace it with "angle right, angle down". ``` /\* dropdown to angle right or down\*/ How do you acquire a dog? ``` Is anyone has expe...
2018/03/08
588
2,134
<issue_start>username_0: I'm trying to update a multi select from the component. i use an object property as the model for the select, when selecting something the object property gets updated as you would expect. the select code in the template: ``` {{ ingredient.title }} ``` the code form the component: ``` a...
2018/03/08
937
3,487
<issue_start>username_0: Trying to execute following query ``` > Resort.findAndCountAll( > { > where: { status: "active", name: { [Sequelize.Op.like]: '%' + _search_like + '%' } }, > attributes: [ > "id", > "name", > "email", > ...
2018/03/08
507
1,863
<issue_start>username_0: When `print(mess)` is called from the `viewDidLoad` function, it prints what is expected in the console, but when it is assigned to a `UITextField` or `UILabel`, then the assigned value is not getting reflected in the `UITextField` or `UILabel`. why is this ? Doing this: ``` var mess: String ...
2018/03/08
478
1,618
<issue_start>username_0: I'm trying to append the text from the title attribute into the `span` element. problem is that my `each function` doesn't work, so it add the same text to all elements. What am I doing wrong? HTML ``` ![](#) [.](# "text to ad to span from first element") ![](#) [.](# "text to ad to...
2018/03/08
406
1,267
<issue_start>username_0: I have the following table: ``` Item tTotal ------------------ A 20 B 10 C 5 ``` I want to have a tsql with a new column, like: ``` Item tTotal oPercent -------------------------------- A 20 57.14 B 10 28.58...
2018/03/08
927
3,475
<issue_start>username_0: How do I write log in .net core application running inside docker container so that log messages will show up in `docker logs` alternatively in Kitematic UI? I've tried almost everything but always end up with no logs from dotnet apps. All the others non-dotnet apps I have in containers like ...
2018/03/08
486
1,864
<issue_start>username_0: here's my case. I have a table named License\_expiration wherein I put the expiration date of the license. My problem is how do I get the expiration date -1 month to display into my dashboard table? im using html&css + php + mysql(mysqli). ex. 2018/04/29 - expiration date. it should appear on...
2018/03/08
3,650
13,295
<issue_start>username_0: I am trying to add an item in tableview cell i.e appending an item to last of tableview cell. I have looked at different answers on stackoverflow but none helped me I analyzed **[THIS ANSWER](https://stackoverflow.com/questions/34932050/how-to-insert-a-new-row-in-bottom-of-the-uitableview-swift...
2018/03/08
631
2,335
<issue_start>username_0: With functions ``` QApplication::desktop()->screenCount(); QApplication::desktop()->screenGeometry(); ``` I find how much screens exist on my system and on which screen coordinates they are located. Now I want to find out on which screen a QWidget is located at. How can I do that? Do I have ...
2018/03/08
759
2,701
<issue_start>username_0: I am trying to dynamically append a option in select list using jQuery: ```js let text1 = "jg"; console.log("length of text: " + text1.length); $("#selectList").append($('', { value: 12, text: text1 })); ``` This time it gives length of text: 7 Now I want to retrieve the selected text fro...
2018/03/08
1,330
4,802
<issue_start>username_0: I am working on creating my own chat application in which I used content-editable `div` as chatbox. I am implementing mention feature where my mention is username wrapped in a span tag followed by a space() but my problem is when I remove space my cursor moves to the end of the div. with space...
2018/03/08
1,370
4,953
<issue_start>username_0: I am now managing an AngularJS app that I didn't develop while trying to learn more about AngularJS. However, I am stuck at this particular issue. I am updating some text on the html code. here is an example. I change this ``` #### Energy Use ``` with this: ``` #### Energy Used ``` an...
2018/03/08
413
1,427
<issue_start>username_0: I'm loading the data into a RecyclerView. I want that after click on "mobile number string" it should be open in phone app without parenthesis means I want to open it in phone like a simple "Indian phone number". In my code it is open like this (879) 321-2686. ``` holder.tv_mobileno.setOnC...
2018/03/08
1,361
3,754
<issue_start>username_0: I have a big data table that is rendered in a plotly plot, and the user can select points in the scatter plot with a region (rectangular or polygon). After processing this select element, I get a dataframe with a list of the 'cluster' each point in the selection belongs to and which 'nth' eleme...
2018/03/08
786
2,600
<issue_start>username_0: I am working on VS2008 using .Net 3.5 framework. I am trying to create a JSON object with the below format, ``` { "types":["KKYQ","TGDF","YHGF"] } ``` I tried the following code, ``` public class OutputJson { public List types { get; set; } } public class Types { public string types...
2018/03/08
579
2,014
<issue_start>username_0: I have the following sample code ``` class c; rand int a; constraint a_c { soft a == 10; } function void post_randomize(); $display("From c the random value is %0d\n", a); endfunction endclass class b extends c; constraint a_c_1 { a inside {[10:100]}; } function vo...
2018/03/08
1,101
4,590
<issue_start>username_0: App quits unexpectedly when I enter this code (using core data). I am using `CoreData` object in this screen for adding and removing data. I don't know why this code crashes the app everytime when I enter this screen. This problem occurs: when I add Category in Core Data Object and when I fetch...
2018/03/08
573
2,068
<issue_start>username_0: This is my collection data. ``` { "_id" : ObjectId("5aa0cc8a53e19d84f80842e1"), "states" : [ { "id" : "1", "name" : "Andaman and Nicobar Islands", "country_id" : "101" }, { ...
2018/03/08
576
2,485
<issue_start>username_0: Here I am using 4 drop down list past `season`,`category`, `Gender` and `division`. Based on validation on `Category`, `gender`, `division` at least one needs to be selected. ``` private void cmbpastseason_SelectedIndexChanged(object sender, EventArgs e) { if (validateComboBox()) { ...
2018/03/08
693
2,125
<issue_start>username_0: While adding a hover on feature for my images, the files i was trying it on ended up not matching the circle appearance that all my other sections have. Here is the code for a section called coworking, no hover. Following that is the code for a section called virtual office, with a hover. ``...
2018/03/08
1,791
5,857
<issue_start>username_0: I am trying to create a function that will bind enter to focus on the next entry field in the "insert' frame. Except, in the case of the last entry field, in which it will return the entered text in all the fields. I have tried using an iterator to get the next entry field to no avail. I am new...
2018/03/08
2,292
9,084
<issue_start>username_0: <https://developer.nvidia.com/sites/default/files/akamai/tools/files/PerfKit_4_5_User_Guide.pdf> > > NVIDIA PerfKit SDK allows graphics developers access to low-level NVIDIA GPU > > ***performance counters*** and NVIDIA ***driver counters***. > > > I want to understand the meaning of ...
2018/03/08
391
1,174
<issue_start>username_0: > > Radio button i have > > > For yes: ``` html+=''; ``` For no : ``` '; ``` On click change radio background color for yes Green and For no Red script what i am using to change color ``` function changeinother(radioid) { var curr=$('#'+radioid).attr('data-for'); if(curr=='no'...
2018/03/08
244
761
<issue_start>username_0: How to remove a line which has this pattern using sed ``` resourceNames: [""] ``` I tried ``` sed -i '/resourceNames: [""]/d' ./sa.yaml ``` A part of file looks like this ``` - apiGroups: [""] resources: ["secrets"] resourceNames: [""] verbs: ["get"] --- ```<issue_comment>username...
2018/03/08
278
1,040
<issue_start>username_0: My app opens to a UITabViewController. It has 3 UIViewControllers a,b,c as the tabs, connected by a Segue. It used to work fine but something happened and now when I run my program, the tabs are displayed and it seems that the controller is working (with NSLogs the viewDidLoad of the first tab...
2018/03/08
517
1,872
<issue_start>username_0: Hi I am getting the following error while running the application What can be the possible reason for the issue? ``` ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════ The following assertion was thrown building Home(dirty, state: _HomeState#f...
2018/03/08
849
3,119
<issue_start>username_0: I have two query results.I need to merge the query result based on a condition. ``` $portfolio = DB::table('architects_portfolio')->get(); $img=DB::table('architects_portfolio_images') ->distinct()->get(['architects_images_id']); ``` and my condition to merge is ``` architects_...
2018/03/08
563
2,048
<issue_start>username_0: ``` if (excellInfoUpdateL3.canSendLetter == "N/A") { return ClosureInfo.canClose ="N"; } else { return ClosureInfo.canClose = excellInfoUpdateL3.canSendLetter; } ``` can above code be written in a single line using if condition or something like that?<issue_comment>username_1: ``` $query...
2018/03/08
625
2,559
<issue_start>username_0: Is it possible to trigger a pipeline in ADF v1 using Powershell script? I found this command "Resume-AzureRmDataFactoryPipeline" to trigger the pipeline, but it does not really start the pipeline.. Please advise.<issue_comment>username_1: `Resume-AzureRmDataFactoryPipeline` will work only on...
2018/03/08
836
2,985
<issue_start>username_0: I have a list of N items in a list. ``` var jobIdArray = new List(); jobIdArray.Add(doc.FieldValues(x => x.JobId).FirstOrDefault()); // the count varies as per the result, 16000, 26000, 33598 etc ``` Now I need to write each 15000 into a separate single txt file. Like > > for 16000 -> 150...
2018/03/08
1,303
5,024
<issue_start>username_0: I'm using the `FBSDKLoginManager` to receive a token for later usage (FB posting) and end up in an **endless loop after confirming the access.** When calling the `FBSDKLoginManager()`, the following popup appears (Sorry, it's in German language... This is the official Facebook popup, where the...
2018/03/08
300
921
<issue_start>username_0: I am unable to **register a user account** in a Laravel project. **Error** ``` SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES) (SQL: select count(*) as aggregate from `users` where `email` = <EMAIL>) ``` Is there a solution?<issue_comment>username_1: M...
2018/03/08
964
3,380
<issue_start>username_0: I want to show a circular progress bar with countdown timer.And the timer starts from 10 mins to 0.In the Textview i am showing timer and that is working fine. But it is not reflecting in the progressbar.Progress bar is not at all changing. Below is the code which i have tried. ``` public clas...
2018/03/08
1,238
4,312
<issue_start>username_0: i have a python class that called student.py where it contains attributes and methods one of these method is called **addStudent(self,name,age)**. it takes 2 arguments. the problem is this function display the name and the age of the new student using the setter method. but the console displa...
2018/03/08
432
1,630
<issue_start>username_0: I have written a PowerShell script which loads a json file and performs certain function on it. I am using: ``` $json = Get-Content 'C:\Users\Documents\test.json' | Out-String | ConvertFrom-Json ``` to load the file which works. But I want to store both these files in a git hub repository. ...
2018/03/08
1,559
4,817
<issue_start>username_0: I am doing an assignment for school, and I am having an odd problem. The object that I have created only accesses the first line of a text file we are using. This is highly problematic for me because if I build a database and can only use the first line, well, so much for usefulness. My instru...
2018/03/08
406
1,535
<issue_start>username_0: Hello I have this code: ``` private void txtNumero_KeyDown(object sender, KeyEventArgs e) { CercaCliente(); } private void txtNote_KeyDown(object sender, KeyEventArgs e) { CercaCliente(); } private void txtNominativo_KeyDown(object sender, KeyEventAr...
2018/03/08
809
1,702
<issue_start>username_0: ``` class Example { public static void main(String args[]){ System.out.println(12+8/5%4*(5-4/5)+4*5); } } ``` Why the output is 37? Can anyone explain? I'm a beginner in java<issue_comment>username_1: Check the [precedence of the operators](http://www.cs.bilkent.edu.tr/~guve...
2018/03/08
935
2,177
<issue_start>username_0: I am new to web development with **Razor pages .net core VS 2017**. I have **index page** that lists my data in the form of rows & columns using EF core Model. I am also providing data filtering options via DropDowns and search box. I want to export this tabular filtered/unfiltered data to e...
2018/03/08
682
2,489
<issue_start>username_0: I want to retrieve the documents with only documentID and document Created DateTime details. I am able to get the DocumentID by following query but how can we get the Document created datetime. ``` select c.id from c ``` However, along with id I need to get the document created date also An...
2018/03/08
702
2,301
<issue_start>username_0: I have a question on getting the index offset to a field in the structure, below is the code I use to test: ``` #include typedef struct ipv4\_pkt\_struct { /\*ethernet hdr\*/ unsigned char DestMacAddr[6] ; unsigned char SrcMacAddr[6] ; unsigned char EthernetType[2] ; /\*IP hdr\*/ unsig...
2018/03/08
442
1,509
<issue_start>username_0: I m using navigation drawer and want to put a launcher icon to the right of navigation drawer icon and put a title on right of launcher icon in `ActionBar`. I m trying this but didn't get the expected result. **Image here :** [![enter image description here](https://i.stack.imgur.com/WJAnW.pn...
2018/03/08
1,262
5,159
<issue_start>username_0: When I create the object SearchResult, I have the constructor call 'setStandardsTable' function that sets variable 'standardsTable'. For some reason I get the error > > Fatal error: Uncaught Error: Call to undefined function > setStandardsTable()... > > > and > > Error: Call to undef...
2018/03/08
902
3,199
<issue_start>username_0: Can I run protractor test without writing manually in command line "webdriver-manager start" ? How can I run "webdriver-manager start" in code? I write in TypeScript.<issue_comment>username_1: You can defined gulp task instead. use npm install gulp & create a gulpfile.js for more information r...
2018/03/08
992
3,610
<issue_start>username_0: In AWS cloud formation, i use the cloud former tool. I can use that tool to create a cloud formation template from existing resources. And then use the template to create a stack. I tested with that tool. It can work, (as in it can create instances with same memory size, with same volume size, ...
2018/03/08
1,290
5,002
<issue_start>username_0: I can select a videos and images but i could not upload in my `webview` ,`kotlin` program. ``` webview.setWebChromeClient(object:WebChromeClient() { override fun onShowFileChooser(webView:WebView, filePathCallback:ValueCallback>, fileChooserParams:FileChooserParams):Boolean { ...
2018/03/08
1,590
6,184
<issue_start>username_0: I have 2 questions regarding this issue. 1. if in laravel/web we have `.env` file to set environment to "development" or production and automatically connect to different database. how about in android/kotlin/android studio? 2. and how to make my application request to my localhost (127.0.2.1)...
2018/03/08
2,048
7,793
<issue_start>username_0: I would like to include a language menu on the top of my webpage where you can select between the languages `English (en)`, `Spanish (es)` and `German (de)` *(More languages might be added in the future)*. My website consists of the three pages `nav.php`, `index.php` and `faq.php`. However, I ...
2018/03/08
438
1,366
<issue_start>username_0: I need to remove the first element from a list (the head) and store the value. How would i go about doing that? Im trying to create a stack in sml and making the pop method<issue_comment>username_1: If you want to remove first element from an array means check below, **HTML** ``` * {{item}}...
2018/03/08
184
664
<issue_start>username_0: I have a mobile application that prints star ratings. Here is my code ``` {{item.rating}} ``` class star on displays colored star class star half displays half colored star class star display not colored star Assuming that {{item.rating}} is 2.50. how do I manipulate that in the span c...
2018/03/08
820
2,345
<issue_start>username_0: Surely this is possible, but I can't seem to find how to do it: I'd like to have a default of a function input, but override the default and get() a variable from the global environment if it exists in the global environment. If it doesn't exist in the global environment, take the default of t...
2018/03/08
511
1,531
<issue_start>username_0: I was practicing `tesorflow` on Colaboratory and my code is as below. There is some issue, the error message is > > "TypeError: unsupported operand type(s) for +: 'map' and 'float'" > > > Can someone tell me what's wrong? thanks! ``` import matplotlib.pyplot as plt import numpy as np x ...
2018/03/08
566
2,205
<issue_start>username_0: I do `make install` on a certain library I should be using. I see `.so` files are copied to `/usr/lib`, but `.h` are not copied to `/usr/include`. Is that right by convention?<issue_comment>username_1: By convention, files should be copied to ``` headers -> $DESTDIR$PREFIX/include libs ->...
2018/03/08
846
3,155
<issue_start>username_0: I have a list that I collecting a list of stock prices that are constantly changing > > List listOfLastPrice1; > > > I know that this list is not constant as the price of stocks is not constant. Meaning if I print it now, and will print it again in 5 minutes, values would change. Why? be...
2018/03/08
416
1,478
<issue_start>username_0: My task is to put the program to docker environment, I use ubuntu container. and the program is written by fortran. When I run the program, I got this error ``` ./cscheck.out: error while loading shared libraries: libgfortran.so.1: cannot open shared object file: No such file or directory ```...
2018/03/08
903
2,592
<issue_start>username_0: I want to sort a List< string> case sensitive with capitals last, i.e. in the order a,aBC,b,bXY,c,A,Ax,B,C,... I have tried ``` Comparison c = (string x1,string x2) => StringComparer.Ordinal.Compare(x1,x2); list.Sort(c); ``` but it returns A,Ax,B,C,a,aBC,b,bXY,c,... Is there any predefin...
2018/03/08
876
2,498
<issue_start>username_0: Using jupyterhub 0.8.1. while making Rest-Api calls to Jupyterhub (for user/services and Servers management in Jupyterhub) we need to provide Authorization headers with Value e.g. "token <PASSWORD>" e.g. of header ``` Authorization: token <PASSWORD> ``` Is there any explanation for "token...
2018/03/08
2,456
7,788
<issue_start>username_0: This is my Angular configuration : ``` Angular CLI: 1.7.2 Node: 6.10.0 OS: win32 x64 Angular: 5.2.5 ... animations, common, compiler, compiler-cli, core, forms ... language-service, platform-browser, platform-browser-dynamic ... router @angular/cli: 1.7.2 @angular-devkit/build-optimizer: 0.3....
2018/03/08
435
1,469
<issue_start>username_0: I have my foo.cabal file looking like this: ``` library exposed-modules: Foo.Bar, Foo.Something hs-source-dirs: lib default-language: Haskell2010 executable foobar main-is: Main.hs other-modules: Utils, -- Local module in ./src Foo.Bar ...
2018/03/08
427
1,365
<issue_start>username_0: Currently i am working in a navigation project and I get two inputs from the user as longitude and latitude. The inputs should be given one after other. What i want is to make this two input as one separated by comma so that if i enter like 41.23, 34.32 , it goes to location of longitude of 41...
2018/03/08
324
1,030
<issue_start>username_0: I need a regular expression that checks the following : a number with 7 digits having the following format : xxxyxxx example : 1112111 -->match , 1111111 -->doesn't match<issue_comment>username_1: This may be possible using backreferences: ``` (\d)\1\1[^\1]\1\1\1 ``` Here `\1` refers to th...
2018/03/08
552
1,664
<issue_start>username_0: I'm trying to count the amount of times a distinct user has used a value. Here's an example. ``` import pandas as pd user = ['1', '2', '3', '1'] val = [['a','b','c'],['a'],['c','d'],['a','d']] df = pd.DataFrame({'user': user, 'val': val}) user val 1 [a, b, c] 2 [a] 3 [c,...
2018/03/08
461
1,637
<issue_start>username_0: I need to get the route param id on layout component. **routing.ts:** ``` { path: 'car/:id', component: CarDetailComponent, canActivate: [AuthGuard] } ``` Briefly I'm doing this to get Car ID on my **layout.component.ts:** ``` public param_id: string; constructor(private route: Activ...
2018/03/08
747
1,894
<issue_start>username_0: Suppose there is a data.table as under: ``` exp <- structure(list( id = c("a", "b"), num1 = c(1L, 5L), num2 = list(c(2L, 5L, 8L), c(6L, 10L, 13L, 19L))), .Names = c("id", "num1", "num2"), row.names = c(NA, -2L), class = c("data.table", "data.frame")) ``` See the dat...
2018/03/08
1,356
4,883
<issue_start>username_0: I found following problem in one of the interviews. Please suggest me the algorithm for this. I don't need code. There are `N` number of people and `N` number of seats in a Cinema hall.Every person has his preference list of seats like: Person 1 -> 1, 2 , 4 Person 2 -> 2 , 5 Person 3 -> 1 ,...
2018/03/08
861
2,581
<issue_start>username_0: ``` ArrayList list1= new ArrayList<>(); ArrayList list2= new ArrayList<>(); for(int i=1;i<=5;i++){ list1.add(i); } System.out.println("List1 "+list1); list2=list1; System.out.println("List2 "+list2 ); list2.add(6); System.out.println("List1 Changed "+list1 ); ``` Output : ``` List1 [1, 2, 3,...
2018/03/08
1,141
2,975
<issue_start>username_0: Is there a smarter way to sum all the values of keys in: ``` hash_1 = { 41 => {"a" => {:a => 4, :b => 8, :c => 3}}, 56 => {"b" => {:a => 5, :b => 4, :c => 8}}, 57 => {"c" => {:a => 8, :b => 9, :c => 3}}, } ``` to get the result: ``` result_hash = {a: 17, b: 21, c: 14} ``` I can get ...
2018/03/08
760
3,040
<issue_start>username_0: When I played tensorflow tutorial, one embedding trick is used in [Wide and Deep](https://www.tensorflow.org/tutorials/wide_and_deep) tutorial like this. The tutorial shows how transfer sparse feature (usually one hot encoding) to embedding vector. I knew there are some approaches to create th...
2018/03/08
257
1,026
<issue_start>username_0: I have a table with an Id field type int in SQL Server. 10 years later, can save more if Id reached the maximum value is 2,147,483,647? How to resolve if the table can not be saved anymore?<issue_comment>username_1: You could always modify the column type. Note that you can't do this while the...
2018/03/08
641
2,307
<issue_start>username_0: The following pattern is quite common in certain places in my code, but it doesn't feel Swifty: ``` if let res = calcSomething() { return res } else { throw err.invalidSomething } ``` In English: return the calue of `calcSomething()` if it returned a non-nil, throw an exception other...
2018/03/08
413
1,332
<issue_start>username_0: I would like to create an expected value (continues). Therefore, I need to make an integral with infinite limits. For example: `integrate(exp(2*x+1),-Inf:Inf)` How could I achieve something like this?<issue_comment>username_1: There are several packages in Julia that allow you to do this. Yo...
2018/03/08
262
888
<issue_start>username_0: I have a little problem. I have a full width row with some css style on it, and in this row I have 2 different column size as you can see in my code. What I need to do is that the **col-xs-12 col-lg-3** & **col-xs-12 col-lg-9** is to be in a container of the website, something like 1220px wid...
2018/03/08
215
875
<issue_start>username_0: I am accessing my application which is on 3rd system.So to access this system I am accessing remote from my local system then again remotely accessing the 3rd system.My UI path flow chart works fine.But I am unable to copy paste the text field from my application to my local system.<issue_comme...
2018/03/08
380
1,254
<issue_start>username_0: I have a property file (`test.properties`) with below contents. The value has only one alphabet ``` key1=D k1ey=A key3=B ``` I want to update all the property values with their ASCII values. ``` key1=068 k1ey=065 key3=066 ``` How can I update the property values as shown above and save it...
2018/03/08
722
3,009
<issue_start>username_0: I'm working with **Firebase cloud functions** and facing errors while deploying the functions. There are different errors every time. Right now, it's `"Server Error: Unexpected Response. Please try again"`. Whereas, Sometimes it's `"Server Error. socket hang up"` I checked `firebase-debug.log`...
2018/03/08
553
2,123
<issue_start>username_0: I've searched on this website and internet but can't seem to get anything to work for this simple request. I just want to display the word relating to the **term** e.g. using the xml column below **TEST** will be extracted. The xml column is as below: ``` ``` I've tried using the following ...
2018/03/08
536
1,999
<issue_start>username_0: I've some problem with Git, I'm unable to push all subfolder with a single push command I have a project directory as below: ``` project | |--main | |__dir1 | | |__file1 | | |__filen | | | |__dir2 | | ...
2018/03/08
803
3,080
<issue_start>username_0: I'm creating a **Realm** object in **Kotlin**. **Realm Object:** ``` open class PurposeModel(var _id: Long?, var purposeEn: String?, var purposeAr: String?) : RealmObject() ``` When I compile the above code I'm getting this error: ``` error: ...