132,726 Archived Topics
Remove Filter ![]() | |
Could someone please tell me what this means. a[ ..., j ] Thank you Software Development python | |
![]() | Can anyone tell me the best way to check the number of bits in a number ? for ex, in 2 set bits are1 , in 3 it is 2. So what is best way today available so as to get that value ? thanks. just give me link of … Software Development c ![]() |
...Just run the program and you'll know whats wrong with it...it gives a -1 value... #include <iostream.h> #include <conio.h> void main() { int array[10],key; cout<<"Enter 10 elements:\n"; for (int c = 0; c < 10; c++) cin>>array[c]; clrscr(); cout<<"\n List of Elements:"; for ( c = 0 ; c < … Software Development c++ | |
Hello, I am trying to fill an array with 20 unique random values between 1 and 60. I know what I need to do to get this to work, but I'm not sure how to do it. Here's what I've got: void fillArray( int arr[], int size) { int arr2[20]; … Software Development c++ | |
I'm creating 7x10 array that filled 0's unless it is copied by ships.Currently I'm having a problem in which I'm not sure how to place the ships inside this grid. this is how i've created the map. Please help as I'm a very beginner in c++. Thank you. void displayBoard() … Software Development c++ | |
> Quoted Text Here i got this code from a book i am practicing with and when i try to compile it returns the following error EmployeeTest.java:30: incompactible types found : java.util.Date required: Date hireDay = calendar.getTime(); please how do i debug it import java.util.*; public class EmployeeTest { public … Software Development java | |
Hi Everyone! I'm a user of Turbo C++ and my professor gave me an activity to make a Fibonacci sequence. No I already have the Code for it and it is working. The only problem is. I don't know how the FOrmula Works. I will show you the Code below: … Software Development c++ programming-construct | |
Hi, I've got a set of folders with each contain many files. I need to extract a specific file extention(.sof) from each of these folders to a new directory(or the same directory in a new folder). Any help is appreciated. Thanks. | |
Good day! I knew this is easy to all of you guys. But I need the most precise way to parse this string "**45:50"** and store the result in **two dimensional array with int as datatype**. The delimeter is "**:**". Thank you! Software Development c++ | |
I'm trying to write a simple sqlite query in c++ using visual studio 2010. My problem is that i can't use a c++ variable inside that query. I was not able to find the right syntax. `sqlite3_prepare_v2(handler, "SELECT * FROM grammateas WHERE username==X;", -1, &statement, 0);` where X i would … | |
What would be the error code for this?? Am I using perror() at right place?? The output shows "No error" #include <stdio.h> #include <conio.h> #define MAX_VAL 32000 int main() { start: int x; printf("Enter a value for x= "); scanf("%d", &x); if (x > MAX_VAL) { perror(""); getch(); system("cls"); goto … Software Development c | |
This is a simple password implementation. void getPassword() { int i = 0, flag = 0 ; char c ; char password[100] ; cout<<"\n Enter Password : " ; while(1) { c = getch() ; if(c! = 13 && c! = 8) { cout<<"*" ; Password[i] = c ; i++ … Software Development c ![]() | |
I wrote the following code to test which is faster: performing a multiplication and division many times, or accessing the results in a vector via iterators(perform the calculations ahead of time), or hard coding the results of those calculations into the program. I actually expected storing the results in the … | |
I was thinking about somehow using a static member that all the matrix cells will be defined by their value + the static value. but than i thought how can i do it? what is the easiest way of doing so without the need to run over the 10^6 cells? … Software Development c++ | |
I am using the (EditingControlShowing) event to Enable AutoComplete in DataGridViewComboBox Column. private void dataGridView1_EditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e) { if (e.Control is DataGridViewComboBoxEditingControl) { ComboBox combo = (ComboBox)e.Control; ((ComboBox)e.Control).DropDownStyle = ComboBoxStyle.DropDown; ((ComboBox)e.Control).AutoCompleteSource = AutoCompleteSource.ListItems; ((ComboBox)e.Control).AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; } } But it has a strange behavior, when I type some characters … Software Development | |
Hi Everybody, I'm sorry if the asnwer is already posted somewhere, I was not able to find it. When I build my solution, I get the following error: 'UserManager.AuthenticateUser(string, string)': not all code paths return a value. Dont know the reason why is this happening. But I have included my … Software Development open-source | |
Hi all, I am currently trying to generate a number from a specified range using a function int number_range(int from, int to) { return (from + rand() % (to-from+1)); } but negative numbers cause the program to crash. How can i go about doing this so it can take numbers … Software Development c | |
I like to have the name of the current method for logging purposes. For example: string Commands::test(StringTokenizer& tokens) { static string src("Commands::test"); ... _log.debug("message", src); } I'm worried that creating 'src' might cause a performance hit. I made the string static thinking it would only be constructed once, the first … Software Development c++ | |
I am trying to make a program that generates a random number and asks the user to input the random number generated by the computer. Anyone know how to do this? This is my program: #include <iostream> #include <cstdlib> #include <ctime> using namespace std; int main() { int one; time_t … Software Development c++ programming-construct | |
![]() | http://www.spoj.pl/problems/BISHOPS/ hey, Can any one please see this problem and tell me how to deal with number like 10^100 ? Please help me out as it is used in many many problems. thanks in advance to everyone. Software Development c |
4B 50 7B F1 F4 F5 5E 50 7B F1 F4 F5 5E 4B 4B 4B Software Development c++ | |
Ok, so, this code snippet is a reply to this thread: http://www.daniweb.com/software-development/cpp/threads/425821/prime-number-c From what I understood form the OPs request, is that, he wanted an algorihm which would check for prime numbers in a given range, applying these conditions: a number is to be considered valid if: a. the number … | |
Basically I'm running into issue, I have a Global Keyboard hook in a DLL, whenever it captures a key it uses WMCopyData to send the keycode over to the MAIN application. The problem is when the main application gets the key code it seems to be corrupt/changes in value. Here … Software Development pascal | |
Hi all. I have a radio group with a bunch of possible selections. User has to select one of the options in order to go on. Is there any faster way than a for loop iterating through the single buttons to verify one has been checked? Thanks | |
HI i have this error null reference i don't know why Imports System.Data.SqlClient Imports System.Configuration Imports System.Configuration.ConfigurationSettings Public Class Form1 Private ConName As New DataAccess Private Sub cmdconnect_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdconnect.Click Dim conn As String Dim m_server As String Dim m_db As String m_server … Software Development vb.net | |
Hi, everyone! This is my first post ever here in Daniweb. I experienced a problem in printing the sorted array of 5 numbers, as the following code only prints the first iteration of the loop, and it does not print the array input. Here's the code: section .data i db … Software Development assembly programming-construct ubuntu | |
I am not able to figure out what's wrong with the following code: Is it a rule to create objects in class that contains main method and then use this object to access the methods? I did exactly reverse in the following code and i am not able to compile … Software Development java | |
I am working on an application that keeps track and uses files stored on the file system. Users are allowed to open, create, delete and move files in the file system. Meanwhile my application is not constantly running so I can't keep track of all changes real-time. Afterwards my application … Software Development file-system microsoft | |
Using cout to produce output - double space = 4.0 - 1.9999999; cout << space << endl; result: 2 Why am I not getting 2.0000001 instead? What should the type be or the numbers to make this 2.0000001? Thanks Software Development c++ | |
Hi all, I have a form that is supposed to query a website. I have the following code that first looks at and uses data from an SQL Server db connection: ConnString = "Data Source=SQL2008T1;Initial Catalog=EconAnalysis;Integrated Security=True" SCqryStr = "" SQLConn.ConnectionString = ConnString SQLConn.Open() SQLStr = "SELECT vSeries_Number FROM tblVSeriesList" … Software Development open-source vb.net | |
hi all, This is my first post in this site. I have a sentence like this String input = "India/world is my Country and it is in Asia/in world"; I want to remove the word followed by the / and get the result of otheres. Output **India is my Country … Software Development java | |
Would anyone know of a reporting toolkit library for C++ which can be compiled as part of a project. It will need to be ablue to display tables, display charts and be printable through a printer. Preferabely free though I haven't been able to find any at all. The closest … | |
Hi I have a program that I am to write that is suppose to read from a text file. I am suppose to assume no more than 100 item and terminate after by -1. have to read and store the data. I have to write a method to print the … Software Development java | |
![]() | int main() { extern int i; i=20; printf("%d\n",i); } hi.. actually this is asked to me today. In this no i is defined anywhere. only declaration is given in main(). then i was asked when the error will come ? like is it segmentation fault, linking error, complilation error or … Software Development c |
![]() | t=input() while t>0: t=t-1 m,n=input().split(" ") m=int(m) n=int(n) m=m%10 n=n%4 if n==1: print (m) elif n==2: print (m*m)%10 elif n==3: print (m*m*m)%10 else: print (m*m*m*m)%10 why this code is giving me NZEC error ? it is irritating me now. thanks Software Development python ![]() |
A means AMA but i cant figure out whats wrong cuz its gotta accept both capital and small letters help please #include<iostream.h> void main() { char x[2]; cout<<"What does the letter A mean in ACLC?"; cout<<endl<<"S:"; cin.getline(x,2); { if(x[0]=='A'||x[0]=='a') x[0]='y'; else x[0]='n'; { } if(x[1]=='M'||x[1]=='m') x[1]='y'; else x[1]='n'; } { … Software Development c++ | |
I have a rootnode and its value is (1) then it's childnode is (2,3) I add childnodes to (2) but on (3) I do not know. how can I add childnodes to 3? Software Development vb.net | |
Hey guys! Need some help with homework again, I have absolutely no idea what this means, could someone explain it to me with some example code? *For the quadratic equation problem, complete the 4th phase: Write the C program according to the algorithm specified in the lesson. File name should … | |
Hello everyone, I progress step by step my problem, one step is passed -now I can send string datas -text messages- here another step is I want to record some audio sounds by using microphone in first android emulator assume phone1 and send to second android emulator-phone2-. I found whole … Software Development android-development audio client-server java socket-programming | |
Hi Buddy, I have a requirement which is explained as below: 1. My input xml file is as shown: <input> <historicalObservation> <observationDate>20110111</observationDate> <observedRate>14.74</observedRate> <observationWeight>1</observationWeight> <observationType>fixing</observationType> </historicalObservation> <historicalObservation> <observationDate>20110111</observationDate> <observedRate>10.28</observedRate> <observationWeight>2</observationWeight> <observationType>fixing</observationType> </historicalObservation> <historicalObservation> <observationDate>20110111</observationDate> <observedRate>27.96</observedRate> <observationWeight>3</observationWeight> <observationType>fixing</observationType> </historicalObservation> <historicalObservation> <observationDate>20110111</observationDate> <observedRate>4.94</observedRate> <observationWeight>4</observationWeight> <observationType>fixing</observationType> </historicalObservation> <historicalObservation> <observationDate>20110225</observationDate> <observedRate>14.18</observedRate> <observationWeight>1</observationWeight> <observationType>fixing</observationType> </historicalObservation> … Software Development xml | |
Hi all, I am trying to write a CWEB c++ program that just keepsgoing until the user types 'no'. Anyway i get some errors that I can't fix. Here is the .w file (x's are comment blocks to save congestion) @* Program Skeleton @ x @c using namespace std;@; @<Header … Software Development c++ | |
Hello Community, I was wondering if its possible to make an editor like [Notepad++](http://notepad-plus-plus.org) (I'm talking about the text area). So it will change the colour of the words (funtions and commands) also with the margin with the numbers and the code folding. Please help with what you can even … | |
4B 50 7B F1 F4 F5 5E 50 7B F1 F4 F5 5E 4B 4B 4B 4B 50 7B F1 F4 F5 5E 4B 50 7B F1 F4 F5 5E 50 7B F1 F4 F5 5E 4B 4B 50 7B F1 F4 F5 5E 4B 50 7B F1 F4 F5 … Software Development c++ | |
Hi....I want to add plus one in Id...the problem is i have to show after getting id from database...code is mycommand = new SqlCommand(query_Id, myconnection); reader = mycommand.ExecuteReader(); reader.Read(); txtID.Text = reader[0].ToString(); reader.Close(); for example in this case i m getting ID 3 in my text box but i want … Software Development | |
this is my code:: <!--school.xml--> <?xml version="1.0" encoding="ISO-8859-1"?> <?xml-stylesheet type="text/xsl" href="school.xsl"?> <UCSC> <student> <name>Isuru ilangakoon</name> <age>21</age> <contct_no>0714234672</contct_no> <degree>computer science</degree> <school>DVharmapala college</school> </student> <student> <name>randika malinga</name> <age>22</age> <contact_no>0713567134</contact_no> <degree>computer science</degree> <school>Nalanda college</school> </student> <student> <name>vinod kawinda</name> <age>22</age> <contct_no>0783451024</contct_no> <degree>computer science</degree> <school>maliyadewa college</school> </student> <student> <name>Inshaf mahatt</name> <age>21</age> <contct_no>0777234151</contct_no> <degree>ICT</degree> <school>D.S.Senanayaka college</school> … Software Development xml | |
Can you Close or Exit an application from within a Sub or what would be the 'best practise' for Exiting when the app has failed a logic test? My app checks for the existance of various files in a Sub Routine off the Form_Load and writes to a log along … Software Development vb.net | |
Hello professionals, can any one tell me how to extract PDF attachments with c#? | |
i have the following situation. how can I change the value in the column in a dataGridView? thanks! Software Development |
The End.