I used a cocoa static library in my application. When I compile my library I got the following error:
Shell Script invocation error:can't open input file:
/Users/sijuthomas/Library/Developer/Xcode/De..
How do I display my time in 24h format instead of 12?
I am using moment.js.
I am pretty sure that these lines could have something to do with it.
meridiem : function (hours, minutes, isLower) {
..
I have a string that represents a non indented XML that I would like to pretty-print. For example:
<root><node/></root>
should become:
<root>
<node/>
</root>
..
I have just recently done an export of my selenium IDE code to selenium web driver. I have found that a lot of the commands that worked in IDE either fail to work or selenium web driver claims to not ..
I'm using Angular 5.
I want to know how can I start timing when a 'play' button is pressed, in order to know how much time has passed since I clicked.
I'd also like to know if it's possible to stop ..
Here's the very dumb way:
def divisorGenerator(n):
for i in xrange(1,n/2+1):
if n%i == 0: yield i
yield n
The result I'd like to get is similar to this one, but I'd like a smarter a..
I am trying to export a list to a CSV file.
I got it all working up to the point I want to write to file to the response stream. This doesn't do anything.
Here is my code:
Call the the method from t..
I'm trying to use a reportviewer control, within a razor view, in the mvc 3 framework. The online documentation talks of drag and drop. Any suggestion on how to insert it into the view...
I have a table with a column that stores the date and time. I need to write a query to get only the date from that column,
SELECT CAST(CONVERT(VARCHAR, LoginTime, 101) AS datetime) FROM AuditTrail
..
Apologies in advance for the simplicity of this question. I am trying to import a .dat file from a website into R with the following code:
www = "http://www.nilu.no/projects/ccc/onlinedata/ozone/CZ03..
The API I'm working with can return empty [] lists.
The following conditional statements aren't working as expected:
if myList is not None: #not working
pass
if myList is not []: #not working
..
How can I get crash data (stack traces at least) from my Android application? At least when working on my own device being retrieved by cable, but ideally from any instance of my application running o..
Is it possible to change a div's width live with jQuery? And if it is, how?
What I want is to change its width depending on the browser's window width in real time, so if/when the user changes the br..
I have data like this:
string 1: 003Preliminary Examination Plan
string 2: Coordination005
string 3: Balance1000sheet
The output I expect is
string 1: 003
string 2: 005
string 3: 1000
And ..
If the data look like:
Store,Dept,Date,Weekly_Sales,IsHoliday
1,1,2010-02-05,24924.5,FALSE
1,1,2010-02-12,46039.49,TRUE
1,1,2010-02-19,41595.55,FALSE
1,1,2010-02-26,19403.54,FALSE
1,1,2010-03-05,2182..
if(prev_clicked)
{
$("#accordion li a.category").css('background-image', 'url("img/off_all_channel.png")');
$("#accordion li a.comment").css('background-image', 'url("im..
On one server, when I run:
mysql> select now();
+---------------------+
| now() |
+---------------------+
| 2009-05-30 16:54:29 |
+---------------------+
1 row in set (0.00 sec)
On..
I've been trying to learn how to use Android Studio but when I attempted to run one of the sample programs I get this error message:
Installation failed with message null.
It is possible tha..
Simple question: Is it possible to get all the data POSTed to a page, even if you don't know all the fields?
For example, I want to write a simple script that collects any POSTed data and emails it. ..
Is there a way to capture browser logs while running automated test cases with Selenium? I found an article on how to capture JavaScript errors in Selenium. But that is just for Firefox and only for e..
I used RandomAccessFile to read a byte from a text file.
public static void readFile(RandomAccessFile fr) {
byte[] cbuff = new byte[1];
fr.read(cbuff,0,1);
System.out.println(new String(c..
I'm writing a simple site that takes as input an idiom, and return its meaning(s) and example(s) from Oxford Dictionary. Here's my idea:
I send a request to the following URL:
http://www.oxfordlearner..
Whats the prettiest way to compare one value against multiples options?
I know there are loads of ways of doing this, but I'm looking for the neatest.
i ask because i'd hoped this was workable (it i..
I am trying to call a PHP function from an external PHP file into a JavaScript script. My code is different and large, so I am writing a sample code here.
This is my PHP code:
<?php
function add..
I've been looking around for ways to select columns through the python documentation and the forums but every example on indexing columns are too simplistic.
Suppose I have a 10 x 10 dataframe
df =..
I am completely new to ASP.Net MVC. I just created an MVC3 project in Visual Studio 2010. The view engine is razor. When I just ran the application it gave the proper result in the browser. The URL i..
I tried to use a make file in code::blocks but I am doing it wrong. I have the version installed with the compilers included. http://sourceforge.net/projects/codeblocks/files/Binaries/10.05/Windows/co..
Is there an easy way to read a single char from the console as the user is typing it in Java? Is it possible? I've tried with these methods but they all wait for the user to press enter key:
char tmp..
I need to see how my webpages are looking on an iPhone and iPad on my windows desktop. Is this possible?
A quick search yielded some iPhone testing sites, which seemed like what I wanted. However, th..
My question is, what is the best way I can map one object to another in the most maintainable manner. I cannot change the way the Dto object that we are getting is setup to be more normalized so I nee..
In another Bruce Eckels exercise in calculating velocity, v = s / t where s and t are integers. How do I make it so the division cranks out a float?
class CalcV {
float v;
float calcV(int s, int..
I'm trying to install Imagemagick on OSX Lion but something is not working as expected.
-> brew install imagemagick
/usr/local/git/bin/git
==> Cloning https://github.com/adamv/ImageMagick.git
..
We (apparently) had poorly executed of our Solaris MySQL database engine last night. At least some of the InnoDB tables are corrupted, with timestamp out of order errors in the transaction log, and a ..
I am a newbie when it comes to JavaScript and it was my understanding that using one SWITCH/CASE statements is faster than a whole bunch of IF statements.
However, I want to use a SWITCH/CASE state..
What does bundle exec rake db:migrate mean? Or just bundle exec rake <command> in general?
I understand that bundle takes care of maintaining things in the Gemfile. I know what the word "exec"..
Looking to use a message queue in a small web app I'm building with node.js. I looked at resque but not sure that's appropriate. The goal is to push notifications to clients based on backend and other..
So I try to import sql file into rds (1G MEM, 1 CPU). The sql file is like 1.4G
mysql -h xxxx.rds.amazonaws.com -u user -ppass --max-allowed-packet=33554432 db < db.sql
It got stuck at:
ERROR 12..
I put a string array elements is a map where elements of string array is key and frequency of word is value, e.g.:
String[] args = {"if","it","is","to","be","it","is","up","me","to","delegate"};
..
I just downloaded eclipse for Java Yesterday but when I was trying to get make my first program, I kept on getting this error:
must declare a named package eclipse because this compilation unit is a..
I have a certain element that I can select with Selenium 1.
Unfortunately I need to click the parent element to get the desired behaviour. The element I can easily locate has attribute unselectable, ..
I have a numpy array, something like below:
data = np.array([ 1.60130719e-01, 9.93827160e-01, 3.63108206e-04])
and I want to round each element to two decimal places.
How can I do so? ..
I want to represent a 2D array with a 1D array. A function will pass the two indicies (x,y) and the value to store. These two indicies would represent a single element of a 1D array, and set it accord..
I have been trying to think of a way to make a table with a fixed first column (and the rest of the table with a horizontal overflow) I saw a post which had a similar question. but the fixed column b..
I'm getting a datetime string in a format like "2009-05-28T16:15:00" (this is ISO 8601, I believe). One hackish option seems to be to parse the string using time.strptime and passing the first six ele..
I was struggling with setting up libsass as it wasn't as straight-forward as the Ruby based transpiler. Could someone explain how to:
install libsass?
use it from command line?
use it with task runn..
I want to include file name 'main.txt' in the subject for that I am passing file name from command line. but getting error in doing so
python sample.py main.txt #running python with argument
msg['..
Are there any dictionary classes in the .NET base class library which allow duplicate keys to be used? The only solution I've found is to create, for example, a class like:
Dictionary<string, Lis..
Is there a way to run this command line within a Java application?
java -jar map.jar time.rel test.txt debug
I can run it with command but I couldn't do it within Java...
I am often ending up with a function producing output for which I don't understand the output data type. I'm expecting a list and it ends up being a list of lists or a data frame or something else. Wh..
I'm trying to create for the first time a Postgres database, so this is probably a stupid question. I assigned basic read-only permissions to the db role that must access the database from my php scri..
I want to leave a bit of space at the beginning of a UITextField, just like here:
Add lefthand margin to UITextField
But I don't know how to do that with Swift...
I am getting that exception from this code:
class Transaction:
def __init__ (self):
self.materials = {}
def add_material (self, m):
self.materials[m.type + m.purity] = m
..
I have 2 MYSQL tables, users and scores. Detail:
users table:
scores table:
My intention is get 20 users list that have point field sort DESC (descending) combine avg_time field sort ASC (a..
I have this method for grabbing the file name from a string URI. What can I do to make it more robust?
private string GetFileName(string hrefLink)
{
string[] parts = hrefLink.Split('/');
stri..
Recently began branching out from my safe place (R) into Python and and am a bit confused by the cell localization/selection in Pandas. I've read the documentation but I'm struggling to understand the..
Using angular 2 beta, I cannot seem to get an <input type="file"> to work.
Using diagnostic, I can see two-way binding for other types such as text.
<form>
{{diagnostic}}
<div..
I want to understand the difference between a branch, a fork and a clone in Git?
Similarly, what does it mean when I do a git fetch as opposed to a git pull?
Also, what does rebase mean in comparis..
I need to consume a Web Service. They sent me the WSDL file.
What should I do to add it to my website and start using it as the proxy.
( If I put it on a Virtual Directory it can be discovered, but d..
I am trying to define a procedure, involved(courses, person), that takes as input a courses structure and a person and returns a Dictionary that describes all the courses the person is involved in.
H..
I am looking for a fast way to preserve large numpy arrays. I want to save them to the disk in a binary format, then read them back into memory relatively fastly. cPickle is not fast enough, unfortuna..
I want to have a vertical menu with a specific height.
Each child must fill the height of the parent and have middle-aligned text.
The number of children is random, so I have to work with dynamic va..
numpy has three different functions which seem like they can be used for the same things --- except that numpy.maximum can only be used element-wise, while numpy.max and numpy.amax can be used on part..
Is there a way to pair a device in linux without requiring a pin(for testing purposes so I need it to be done w/out human interaction, assuming you have root access)?
bluez-simple-agent seems to requ..
I have some data in an hidden field on a jsp page
<input type=hidden id="thisField" name="inputName">
how to access or pass this field onsubmit to another page?..
How do I set a data attribute without adding a value in jQuery? I want this:
<body data-body>
I tried:
$('body').attr('data-body'); // this is a getter, not working
$('body').attr('data-body..
Getting this error with the following query in SQL Server 2012.
An expression of non-boolean type specified in a context where a condition is expected, near 'RETURN'.
CREATE FUNCTION [dbo].[GetPMRes..
By default, copying from the command prompt will prompt you to overwrite files that already exist in the target location.
You can add "/Y" to say "Yes to all" replacements.
But how can you say "No t..
I am using R and I have two data frames: carrots and cucumbers. Each data frame has a single numeric column which lists the length of all measured carrots (total: 100k carrots) and cucumbers (total: 5..
How to switch to specific Git commit without losing all the commits made after it?
I want that local files will be changed, but commits' database will remain intact, only the current position pointer..
From a bash script how can I quickly find out whether a port 445 is open/listening on a server.
I have tried a couple of options, but I want something quick:
1. lsof -i :445 (Takes seconds)
2. netst..
Sry if this question already exists, but I've been searching for quite some time now.
I have a dictionary in python, and what I want to do is get some values from it as a list, but I don't know if th..
I would like to create a very simple C application that does an HTTP post. It will take a few parameters, and use these to construct a URL. I'd just like to do a simple HTTP POST and get the respons..
Trying to call a method in my activity from a fragment. I want the fragment to give the method data and to get the data when the method return. I want to achieve similar to call on a static method, bu..
Does anyone know if exists any official or most accepted reference for Angular naming conventions to use when we build our applications?
Angular has many different types of components such as filters,..
I am writing a cross-platform C++ program for Windows and Unix. On the Window side, the code will compile and execute no problem. On the Unix side, it will compile however when I try to run it, I get ..
I'm writing a Windows batch file and want to copy something to the desktop. I think I can use this:
%UserProfile%\Desktop\
However, I'm thinking, that's probably only going to work on an Engli..
I am new to python and couldn't find the answer to this. Referring to the code at the end of the message, can I know what does the part "for item, total in totals.items()" in the line below mean?
ran..
Is there way to initialize a numpy array of a shape and add to it? I will explain what I need with a list example. If I want to create a list of objects generated in a loop, I can do:
a = []
for i in..
I always assumed that chaining multiple filter() calls in Django was always the same as collecting them in a single call.
# Equivalent
Model.objects.filter(foo=1).filter(bar=2)
Model.objects.filter(f..
I want to write a shell script to automate a series of commands. The problem is some commands MUST be run as superuser and some commands MUST NOT be run as superuser. What I have done so far is someth..
I am trying to create a Local IIS Website using ASP.NET.
When I click on New -----> Website and select the type as HTTP and from the dialog box if I select the option as LOCAL IIS WEBSITE I am get..
In LaTeX, how can I define a string variable whose content is used instead of the variable in the compiled PDF?
Let's say I'm writing a tech doc on a software and I want to define the package name in..
I know there is a lot of controversy (maybe not controversy, but arguments at least) about which naming convention is the best for JavaScript.
How do you name your variables, functions, objects and s..
I am getting the current date (in format 12/31/1999 i.e. mm/dd/yyyy) as using the below code:
Textview txtViewData;
txtViewDate.setText("Today is " +
android.text.format.DateFormat.getDateFor..
I tried everything that is written in this article: http://www.asp.net/web-api/overview/security/enabling-cross-origin-requests-in-web-api, but nothing works.
I'm trying to get data from webAPI2 (MVC5..
Going crazy with this error from about a couple of hours.
The error is:
failed to find Build Tools revision 23.0.0 rc1
But I think to have all update (also the release candidate!)
This is the ima..
I have been trying to reset my MySQL root password. I have run the mysqld_safe --skip-grant-tables, updated the root password, and checked the user table to make sure it is there. Once restarting th..
I've updated my SDK to API 21 and now the back/up icon is a black arrow pointing to the left.
I would like it to be grey. How can I do that?
In the Play Store, for example, the arrow is white.
I'..
For educational purposes, I need to send an email through an SMTP server, using SMTP's fundamental and simple rules.
I was able to do that using smtp4dev. I telnet localhost 25 and and commands are:..
I'm coding in C++. If I have some function void foo(vector<int> test) and I call it in my program, will the vector be passed by value or reference? I'm unsure because I know vectors and arrays a..
I'm looking for a quick way to type the Enter or Return key in Selenium.
Unfortunately, the form I'm trying to test (not my own code, so I can't modify) doesn't have a Submit button. When working with..
When trying to compile with Xcode, I am getting the following error:
**Ld /Users/doronkatz/Library/Developer/Xcode/DerivedData/iKosher-bphnihrngmqtkqfgievrrumzmyce/Build/Products/Debug-iphonesimula..
Using a Linux shell, how do I start a program with a different working directory from the current working directory?
For example, I have a binary file helloworld that creates the file hello-world.txt..
What is getSource? and what does it return?
and what is getActionCommand() and what does it return??
I am getting confused between these two can anyone give or differentiate them to me? what's the u..
I have a DropDownList that asks the user if he want to join the club:
Do you want to join the club
Yes
No
Under this list there is another list that is set to disabled as a default. This list has t..
Is there a recommended way to escape <, >, " and & characters when outputting HTML in plain Java code? (Other than manually doing the following, that is).
String source = "The less than si..
I am new to Python and want to read keyboard input into an array. The python doc does not describe arrays well. Also I think I have some hiccups with the for loop in Python.
I am giving the C code sn..
I'm trying to determine how to count the matching rows on a table using the EntityFramework.
The problem is that each row might have many megabytes of data (in a Binary field). Of course the SQL wou..
Say you need to have a list/array of integers which you need iterate frequently, and I mean extremely often. The reasons may vary, but say it's in the heart of the inner most loop of a high volume pro..
Does anyone know the difference between String and string in TypeScript? Am I correct in assuming that they ought to be the same?
var a: String = "test";
var b: string = "another test";
a = b;
b = a;..
I know that if you compare a boxed primitive Integer with a constant such as:
Integer a = 4;
if (a < 5)
a will automatically be unboxed and the comparison will work.
However, what happens when ..
I have an form with autocomplete disabled but it does not works and makes the autocomplete to be enabled in firefox and higher version of chrome
<form method="post" autocomplete="off" action="">..
I am new to the OpenFileDialog function, but have the basics figured out. What I need to do is open a text file, read the data from the file (text only) and correctly place the data into separate text..
Trying to get a large (and working on Xcode 11!) project building in Xcode 12 (beta 5) to prep for iOS 14. Codebase was previously Obj-C, but now contains both Obj-C and Swift, and uses pods that are..
I have a Git repository that has several submodules in it. How do I list the names of all the submodules after git submodule init has been run?
The git submodule foreach command could echo the names ..
How can I create an ant fileset which excludes certain directories based on the contents of the directory?
I use ant to create a distribution jar which has each localization in separate directories, ..
Possible Duplicate:
how to convert date from yyyyMMdd format to mm-dd-yyyy fomrat
I have a string which contains date in yyyyMMdd format. I want to convert that date into system date format..
I'd like to see all the events fired by an input field as a user interacts with it. This includes stuff like:
Clicking on it.
Clicking off it.
Tabbing into it.
Tabbing away from it.
Ctr..
Can someone explain to me what is the purpose of meshgrid function in Numpy? I know it creates some kind of grid of coordinates for plotting, but I can't really see the direct benefit of it.
I am stu..
Is there a way to have all links on a page be relative to the root directory?
For example, on www.example.com/fruits/apples/apple.html I could have a link saying:
<a href="fruits/index.html">B..
I'm trying to use the Html.DropDownList extension method but can't figure out how to use it with an enumeration.
Let's say I have an enumeration like this:
public enum ItemTypes
{
Movie = 1,
..
This is the query I'm using:
DELETE TB1.*, TB2.*
FROM TB1
INNER JOIN TB2 ON TB1.PersonID = TB2.PersonID
WHERE (TB1.PersonID)='2'
It's working fine in MS Access but getting error (Inc..
I have an issue while using buttons inside form. I want that button to call function. It does, but with unwanted result that it refresh the page.
My simple code goes like this
<form method="POST"..
I have a pom.xml in C:\Users\AArmijos\Desktop\Factura Electronica\MIyT\componentes-1.0.4\sources\pom.xml and I executed:
mvn install:install-file -DgroupId=es.mityc.jumbo.adsi -DartifactId=xmlsec-1.4..
I have Angular2 project build with Angular-CLI (beta 20).
Is there a way to run tests against only one selected spec file?
I used to have a project based on Angular2 quick start, and I could manual..
My password strength criteria is as below :
8 characters length
2 letters in Upper Case
1 Special Character (!@#$&*)
2 numerals (0-9)
3 letters in Lower Case
Can somebody please give me regex..
I am producing a sheet to calculate prices. The sheet has to have a reference to several other workbooks to get the prices for different components. This works fine on my computer but when I move them..
I have a method:
public DzieckoAndOpiekunCollection GetChildAndOpiekunByFirstnameLastname(string firstname, string lastname)
{
DataTransfer.ChargeInSchoolEntities db = new DataTransfer.ChargeInSc..
I know that waitpid() is used to wait for a process to finish, but how would one use it exactly?
Here what I want to do is, create two children and wait for the first child to finish, then kill the s..
I'm new to Python and I have a simple question, say I have a list of items:
['apple','red','apple','red','red','pear']
Whats the simpliest way to add the list items to a dictionary and count how ma..
I am creating three EditTexts in my xml file using code like this:
<EditText
android:id="@+id/name_edit_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
..
I am creating a website, but when I made changes to the stylesheet on my site, and I refreshed the site, none of the changes were there.
I tried to use the view source tool to check the stylesheet.cs..
I am developing a SpringBoot project and I want to get the bean by its name using applicationContext. I have tried many solution from web but could not succeed. My Requirement is that I have a control..
I am using the jQuery $.ajax() function. I have put this into a parent function, which passes some values into the ajax function. What I would like to do, is have a user defined callback function, w..
Here is my Java code which is used for the de-serialization,
i am trying to convert json string into java object. In doing so i have used the following code:
package ex1jackson;
import com.fasterxml..
This if-condition is what's giving me trouble:
if (div id=myfav has children) {
do something
} else {
do something else
}
I tried all the following:
if ( $('#myfav:hasChildren') ) { do some..
So I am trying to iterate through a worksheet in an Excel spreadsheet using VBA. I want to iterate through each row, and then through each column, and despite googling, I can't actually find an intuit..
I want to group my dataframe by two columns and then sort the aggregated results within the groups.
In [167]:
df
Out[167]:
count job source
0 2 sales A
1 4 sales B
2 6 sales C
3 ..
I'm having some problems installing vows via npm in zsh. Here's what I get. I tried installing it with and without the -g option. Do you have any idea what's wrong here?
[? ~/Desktop/sauce-node-demo..
I would need to rename a few columns in some tables in a SQLite database.
I know that a similar question has been asked on stackoverflow previously, but it was for SQL in general, and the case of SQLi..
I need to run a java jar in server in order to communicate between two applications. I have written two shell scripts to run it, but once I start up that script I can't shut down / terminate the proce..
First, please bear with me. I have hard time telling others my problem and this is a long thread...
I am using pythonbrew to run multiple versions of python in Ubuntu 10.10.
For installing pythonbre..
I have an Insert stored procedure which will feed data to Table1 and get the Column1 value from Table1 and call the second stored procedure which will feed the Table2.
But when I call The second stor..
I've been reading about "web services" here on SO, on Wikipedia, Google, etc., and I don't quite understand what they are. What is the plain English definition/description?
If I make a simple websit..
Is there any way to plot a bar plot using matplotlib using data directly from a dict?
My dict looks like this:
D = {u'Label1':26, u'Label2': 17, u'Label3':30}
I was expecting
fig = plt.figure(..
How can I change the following code to look at all the .log files in the directory and not just the one file?
I need to loop through all the files and delete all lines that do not contain "step4" or ..
Possible Duplicate:
Full path from file input using jQuery
I have the following html element
<input type="file" id="upload">
If I use
$("#upload").val();
I only the file name,..
Duplicate: This is a duplicate of Best practices to parse xml files with C#? and many others (see https://stackoverflow.com/search?q=c%23+parse+xml). Please close it and do not answer.
How do you p..
I am able to do this:
<div id="myDiv">
<div class="foo"></div>
</div>
myDiv = getElementById("myDiv");
myDiv.querySelectorAll("#myDiv > .foo");
That is, I can succes..
I would like to remove and/or deactivate the Emmet package in Sublime Text 2.
Should I just remove the Emmet directory or what is the typical workflow for removal of a package?..
I would like to know if there is a way to convert a 24 Hour time formatted string to a TimeSpan.
Right now I have a "old fashion style":
string stringTime = "07:35";
string[] values = stringTime.Spl..
I'm telling my program to print out line 53 of an output. Is this error telling me that there aren't that many lines and therefore can not print it out?..
When I require a file, for example (called st.rb):
require 'rubygems'
require 'mongrel'
class TestHandler < Mongrel::HttpHandler
def process(request, response)
response.start(200) do |head..
I have just created a very simple chrome extension and it works fine. But when I converted to .crx file and try to open it with chrome, nothing happens. my chrome browser version is 19.0.1081.2 dev-m...
I am running a server on Windows XP SP2 computer using EasyPhp. Lets call it computer_1.
The ip address of computer is 192.168.1.2
Now I have another computer ( computer_2) on the lan with ip address..
I have a script that is appending new fields to an existing CSV, however ^M characters are appearing at the end of the old lines so the new fields end up on a new row instead of the same one. How do I..
I couldn't find anything about getting the total JSON record count using jQuery.
Here is the JSON returned:
{"Email":"Please enter your Email.","Password":"Please enter a password."}
Here is my cod..
As I was programming, I haven't seen an instance where an array is better for storing information than another form thereof. I had indeed figured the added "features" in programming languages had imp..
I am trying run a spring-boot application which uses hibernate via spring-jpa, but i am getting this error:
Caused by: org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null..
I have 5 addons/extensions for FF, Chrome, IE, Opera, and Safari.
How can I recognize the user browser and redirect (once an install button has been clicked) to download the corresponding addon?..
I want to know how malloc and free work.
int main() {
unsigned char *p = (unsigned char*)malloc(4*sizeof(unsigned char));
memset(p,0,4);
strcpy((char*)p,"abcdabcd"); // **deliberately sto..
I work on a dataframe with two column, mvv and count.
+---+-----+
|mvv|count|
+---+-----+
| 1 | 5 |
| 2 | 9 |
| 3 | 3 |
| 4 | 1 |
i would like to obtain two list containing mvv values and c..
I'm about to start a new job where the coding practices are heavily centered around TDD and refactoring, and whose primary development language is Python. I come from the Java world, and have been a ..
I have been using OpenJDK for ages, initially for small projects where it has no problems. But since I started to play with it for big toys, I started to notice random/unknown fatal error and crashes ..
I have an HttpClient that I am using for a REST API. However I am having trouble setting up the Authorization header. I need to set the header to the token I received from doing my OAuth request.
I sa..
Is there any way with CSS to target all inputs based on their type? I have a disabled class I use on various disabled form elements, and I'm setting the background color for text boxes, but I don't wa..
Is there a way to ng-repeat a defined number of times instead of always having to iterate over an array?
For example, below I want the list item to show up 5 times assuming $scope.number equal to 5 i..
<h1>{{header}}</h1>
<!-- This Back button has multiple option -->
<!-- In home page it will show menu -->
<!-- In other views it will show back link -->
<a ng-href="{{..
I'm coming from the angular world where I could extract logic to a service/factory and consume them in my controllers.
I'm trying to understand how can I achieve the same in a React application.
Let..
For now I have a slight idea about the differences between SOAP and RESTful services.
My question is when I should use SOAP, and when I should use RESTful; which one is "better" when it comes to perf..
Let's say I have an Array of numbers: [2,3,3,4,2,2,5,6,7,2]
What is the best way to find the minimum or maximum value in that Array?
Right now, to get the maximum, I am looping through the Array, an..
My understanding is that the [NotMapped] attribute is not available until EF 5 which is currently in CTP so we cannot use it in production.
How can I mark properties in EF 4.1 to be ignored?
UPDATE:..
I need to add custom header to my table
I try this
func tableView(tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
let view = UIView(frame: CGRect(x: 0, y: 0, width:..
My questions are:
How do I change the overall colors (background and font)?
How do I change the colors based on the file type that is open?
Do I need to learn how to create a whole theme?
I read ..
is there a way to configure bower not only to use a proxy but ignore the proxy configuration for some domains?
I have the problem, that I will run an internal bower registry for our own developed com..
I need to split my String by spaces.
For this I tried:
str = "Hello I'm your String";
String[] splited = str.split(" ");
But it doesn't seem to work...
How do I turn on all error and warnings and log them to a file, but to set up all of that within the script (not changing anything in php.ini)?
I want to define a file name and so that all errors and..
This might be ridiculously easy for you but I've been struggling with this for an hour... :(
<?php
$connect = mysql_connect("localhost:8080", "root", "mypassword");
echo($connect);?>
This is ..
I have a dynamic web page where I need to import an external JS file (under an IF condition) inside another javascript file.
I tried to search for a feasible solution but it didn't work.
I have tri..
I have a list 'abc' and a dataframe 'df':
abc = ['foo', 'bar']
df =
A B
0 12 NaN
1 23 NaN
I want to insert the list into cell 1B, so I want this result:
A B
0 12 NaN
1 23 ['foo',..
For example, Java's own String.format() supports a variable number of arguments.
String.format("Hello %s! ABC %d!", "World", 123);
//=> Hello World! ABC 123!
How can I make my own function that ..
Yesterday I went for an interview where I have been asked to create a program to find largest and smallest among 5 numbers without using array.
I know how to create the program using array.
int lar..
Can someone help to change this to incorporate an image called BUTTON1.JPG instead of the standard submit button?
<form id='formName' name='formName' onsubmit='redirect();return false;'>
&l..
I am creating a web application, where you have to read a list of objects / entities from a DB and populate it in a JSF <h:selectOneMenu>. I am unable to code this. Can someone show me how to do..
I want to get the caller class of the method, i.e.
class foo{
bar();
}
In the method bar, I need to get the class name foo, and I found this method:
Class clazz = sun.reflect.Reflection.getCa..
I work with an advertising company, where we tag certain pages to track activity. A client of mine wants to fire off a javascript tag to track activity AFTER the page has finished loading entirely (to..
I am facing this problem since more than a month, here is what I see when I run java on command line:
$ java -Xmx1300m
Error occurred during initialization of VM Could not reserve enough space for o..
I have a program that outputs to stdout and would like to silence that output in a Bash script while piping to a file.
For example, running the program will output:
% myprogram
% WELCOME TO MY PROGR..
This may be something common and trivial, but I seem to be having trouble finding a concrete answer. In C# there is a concept of delegates, which relates strongly to the idea of function pointers from..
So Im learning to develop in Rails, and have discovered the power of zsh. However, for some of my other tasks, I wish to use normal Bash. Although they are the same, I just feel comfortable with the l..