132,726 Archived Topics
Remove Filter ![]() | |
Hey so I have create a class FunWithIntegers. Add a method to the class called GreaterThanFive. Have that method accept an array of int. The method should allocate a new array that contains only the values from the first array that are greater than 5 and return it. [CODE] public … Software Development java | |
hello, i want to get some guidance from the reader who read my post. I'm doing a game called deal or no deal using c++ and i can't think of other way to print the box's number instead of printing the value inside. what i want to do is, user … Software Development c++ | |
Dear All, I'm new to C, and would appreciate your help about the below code. The purpose of the program is to multiply the elements of the array and print the result. The user enters the value for how many elements he wants to have multiplied, and then the function … Software Development c mathematics | |
[CODE]#include <iostream> #include <string> using namespace std; class shapes { protected: int width; int height; public: shapes() { width=0; height=0; } ~shapes() { } void getWidth() { cout<<"What is the width"<<endl; cin>>width; } void getHeight() { cout<<"What is the height"<<endl; cin>>height; } }; class rectangle:public shapes { public: void area() … Software Development c++ | |
i want to make random numbers for x[row][col] that row =10 and col =10, but my problem is: how i fix random numbers of n[col]=5; here is my code: public static void main(String[] args){ double[][] x= new double[10][10]; int row,col; int n[]={0,0,0,0,0,0,0,0,0,0}; for(row=0; row<10; row++ ){ for(col=0; col<10; col++){ if( … Software Development java | |
Hello, Here I have a problem, I want to print the word after the Delimiters in a simple text file, but i cant able to do it also cant able to find a good example for that in a web. So please if anyone help for this. Software Development java | |
Hello everyone, I came across the following in a book: [CODE]Keyword typename The keyword typename was introduced to specify that the identifier that follows is a type. Consider the following example: template <class T> Class MyClass { typename T:: SubType * ptr; ... }; Here, typename is used to clarify … Software Development c++ | |
[CODE]#include<stdio.h> #include<conio.h> #include<stdlib.h> #include<string.h> #include<time.h> void main() { int i[100]; int j[100]; int k; int m; clrscr(); printf("Enter the number of questions needed:"); scanf("%d",&m); if (m<=100); { i[100]=rand()%m; printf("%d \n",i,rand()); j[100]=rand()%m; printf("%d",j,rand()); i[100]=rand()%m; printf("%d \n",i,rand()); j[100]=rand()%m; printf("%d",j,rand()); } getch(); } [/CODE] I want to generate random numbers when I press … Software Development c | |
I found a good tutorial and added a few things to it such as text on screen using the TTF dll, the code worked fine before setting up the font and attempting to display it. I still get no errors or warnings it just compiles then closes instantly :(, no … Software Development c++ open-source | |
How do interpreters do it? I've seen bots for games that encrypt files then decrypt them at runtime and run what's in them.. Well How? How can I do this in C++? I plan to do this in another language but I decided to ask in C++ section because this … Software Development c++ | |
How do strings work? In C we must declare the size of a char array to represent a "string". But in java we do not allocate memory for the size of a string. So how does the string work? Is there a pre deterimed size assigned to strings from the … Software Development java | |
![]() | Hi everyone, I hope you can help me with this. I have everything in my code working properly except for the fact that the payment amounts are being displayed in the command window and I need to display them in the text area, as well as adding scroll bars to … Software Development display gui java java-swing oracle ![]() |
Hi, I'm trying to make a simple calculator. I don't know how to make the display screen and my buttons are not aligned properly. [code]import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.awt.event.*; public class Calculator extends JFrame{ private JButton btn0 , btn1, btn2, btn3, btn4, btn5, btn6, btn7, btn8, btn9, … Software Development java java-swing | |
Hi I have a folder containing a lot of shortcuts so i need to check if the shortcuts paths exist Thank you Software Development | |
I have been working on this for some time and need some help. I have posted to another forum with no results. I figured i would try here and see if i can get some real help. I am trying to populate an array with the contents of a file … Software Development c | |
As part of our exam project we need to write a GUI in java, the problem is that the structure has got us stumped. I'm not asking you to do our work, but if someone could nod us of in the right direction it would really be appreciated. We want … Software Development data-structure gui java java-swing | |
Hi All, I need some help in understanding something. I have an existing database and I make some changes in Sql Server Management Studio, how can I adapt those changes in the Visual Basic project. As an example if I change a table name in Sql Server Management Studio how … Software Development sql vb.net visual-basic visual-studio | |
I'm trying to check the length of a string, its the most simple way there is but for some reason it says the the length of the string is 14h [CODE] org 100h mov cl,len mov si,offset src mov di,offset dst rep movsb mov ah,0 int 16h ret src DB … Software Development assembly | |
I've got a linklist class and would like to have the ability to create a new node that can instantiate it's own new linklist. (some what of a multidimensional link list) I've tried the line: linklist *self = this; but my program crashes when i exit. any thoughts? Software Development c++ | |
Hi All, My wife is into the slimming world diet and has magazines with her favorite diets marked, so I decided to write her a desktop application so she can save all her recepies and tidy all those magazines. So please see my code for my breakfast form below [CODE] … | |
I have the following code and I want to move from one button to an other depending on the roll of the dice,for example if the dice rolls 5 i want to go to (1+5) six and to put a diferent color to it and so on.Can you help me. … Software Development gui java java-swing | |
Hi everybody, I have a crazy problem with a basic calculator. [CODE]#include <iostream> using namespace std; main (){ int num; int y; int ans; cin >> num; for (int x = 0;x < num;++x){ cin >> y; ans += y; cout << ans << endl; } } [/CODE] it take … Software Development c++ | |
I'm typing the code: [CODE] import cmath import math print r"pow(2,3) returns 2^3 pow(2,3,1) returns 2^3 modulo 1" pow(2,3) pow(2,3,1) [/CODE] and I'm getting this error: File "sample2.py", line 26 print r"pow(2,3) returns 2^3 pow(2,3,1) returns 2^3 modulo 1" pow(2,3) pow(2,3,1) ^ SyntaxError: invalid syntax Why is this invalid syntax? Software Development python | |
Hi, I would like to create a web-based directory using GridView. The concept is same on Windows Explorer where there are Folders and Subfolders. The thing is, I will be using it on Binary files on the database. I'm not quite sure about the database structure if the user is … Software Development c# file-system | |
Is there any reason you would want to write your own RTTI system for use in your code, when there already is one in C++? Software Development c++ | |
Hi everyone! I'm experiencing some trouble with a fairly simple problem I guess. First of all, I'm not a real expert when it comes to java, but I would like to learn it mostly by self study. And I'm sorry for the lots of code, but I can't really specify … Software Development java java-swing | |
how can i filter records based on dates especially when the option is for weekly basis?? and then the report will be generated in crystal report. any query or syntax??? i badly need this.. tnx in advance.. im using vb6 and crsytal report 8 and my database is MYSQL Software Development visual-basic | |
hi guys i have existing column in datagridview sample column name (Student ID, Last Name) now i have mysql table column name sample(STUD_ID,LNAME) STUD_ID = int Type, LNAME= varchar Type. i used these code to display mysql table in datagridview if their is no Existing column [CODE] void dlist(string sqlQry, … Software Development dataset | |
Hi, i have a client which reads from the socket: [CODE] for (index=0;index<SCALERS;index++) { read(my_socket,vectorScalerPointer,BUFLEN); read(my_socket,resultScalerPointer,BUFLEN); sum+= atoi(vectorScaler)*atoi(resultScaler); }[/CODE] and a server program which writes to it. [CODE] for (index=0;index<SCALERS;index++) { sprintf(ascii,"%d",(*matrixStruct)._vector[0][index]); write(fd,ascii,BUFLEN); sprintf(ascii,"%d",(*matrixStruct)._mat[atoi(whichRow)][index]); write(fd,ascii,BUFLEN); }[/CODE] now the problem is the programs are in a "race condition" usualy the server … Software Development c c# c++ client-server | |
Hi guys I have a bit of a problem here about the alignment no what I try it always end up like that, the 2nd-3rd row course and sexcode column is what I want to fix >.< package studlist; here's my code: public class StudList { public static void main(String[] … Software Development java | |
Hi again!And happy new year to all.Just got to attained an interview and was asked about some c questions.Would like to know what does these lines means?Can anyone tell me? [CODE]int main() { int k=printf("Hello"); return 0; exit(10); } [/CODE] I got answeres like [QUOTE]You're outputting "Hello" on the screen … Software Development c | |
Hello, I'm a newbie in vb :D however with all the information and help this forum had provided i reach this far with my code BUT i can't proceed anymore. I'm trying to make a small software which will help me in my work. I can't get it to work … Software Development dataset open-source vb.net | |
I wanna know what type of parser is used in the gcc and turbo c++ compilers. whether a top-down or bottom-up parser is used..... ? Software Development c++ | |
I wanna know what type of parser is used in the javac compiler. whether a top-down or bottom-up parser is used..... ? Software Development java | |
Hi, i need to write a recursive function which gets a list and an integer k and returns a list of all the possibilities of creating sub lists to the length of k with the elements from the original list. i hope i was clear enough.. here are some examples: … Software Development python | |
I have a program that reads from a database, and then displays the results in a TextArea. Then when the user hists upload the file will be saved to a .txt file, and then uploaded to the database. But currently I am getting the original which looks like this in … Software Development file-system java | |
Hi guys, I'm writing a weasel program and needed a random character generator, I used a random number generator to give an ascii code for each character, and made a sequence of them, then I realized I needed to include the "space" symbol, but upon inclusion of the new code … Software Development c++ | |
I am in an 11th grade computer science class learning C++ and I feel that the class is going to end before I learn how to apply C++. What I want to know is what do I need to learn to start applying C++ into tasks like software development, game … Software Development c++ | |
I am having trouble setting up these classes. I need to set up a customer collection class that has one function GetCustomer(ByVal customerNumber As Integer) As Customer The customer class reads a file and returns 5 fields and x number of records. My question is do I set up the … Software Development vb.net | |
I have created an XML schema that holds flights and i want to use to be able to create an XML document that contains all the flights. However, i can only write single flights to the XML file. So can anyone tell me how i can add multiple flights to … Software Development java java-netbeans xml | |
Hello. I need some help with variable types. I am currently an 11th grader taking my first Computer science class. I am learning C++ and I would like to know how I can make 10/3 3.33 rather than 3 in C++. For example, a member on the forums updated my … Software Development c++ data-science | |
Im writing a java system for some one, and no contract has been established so far. Im just wondering, if i dont sign any contract, to whom does the source code of my project belong to? Is it mine? do i sell it to him? does he just get it? … Software Development java ![]() | |
I read that using a policy class for a function that will be called in a tight loop is much faster than using a polymorphic function. However, I setup this demo and the timing indicates that it is exactly the opposite!? The policy version takes between 2-3x longer than the … Software Development c++ | |
I'm trying to make a camera app using AVCaptureSession. For now I just want to see if the video input works or not. But it looks like there is no input and I can't seem to understand why. - (void)viewDidLoad { [super viewDidLoad]; session = [[AVCaptureSession alloc] init]; [self addVideoPreviewLayer]; … Software Development image ios iphone objective-c | |
hi everybody, the double type is 8B, right ? So if i use this code : [CODE]double pear[500000000];[/CODE] it will use 4GB of Ram ? or there's a limit for arrays ? thanks Software Development c++ | |
Hello first sorry for my english... my problem is when creating xml from dataset in my dataset i got tables with relations. here is my xml sample that i have created.. but i dont want this. in this one column orders are wrong <ozel> <vergiToplami>1107.46</vergiToplami> <kismiVergiToplami>0</kismiVergiToplami> <toplamKDV>1107.46</toplamKDV> <toplamIadeEdilebilirKDV>0</toplamIadeEdilebilirKDV> <tecilEdilecekKDV>0</tecilEdilecekKDV> <tevkifatUygulanmayanlar> … | |
When you want to draw something on a form you need a Graphics object. But a Graphics constructor isn’t public and if that is not enough the Graphics class is also sealed! This means you can’t create a Graphics object via the new keyword nor can you derive from the … Software Development c# mathematics | |
Greetings! I have a win32 native dll (perhaps that's not the correct term - it's basically a C compiled dll) that I'm accessing in C#. The method signature of the C code (not the actual signature in the dll): [code=C++] char* TestMethod() [/code] I'd like to access the [B]char*[/B] as … Software Development c# | |
I have to sort a large array of numbers wherein the numbers are random and range from 1 to 9,99,999...till the time the length of array is less than 2,00,000, all sorts work fine (i tried selection, insertion and quick sort)...but when the length of array is increased to 3,00,000 … |
The End.