199,114 Archived Topics
Remove Filter ![]() | |
explain the output:-- [CODE] int main(void) { int a=10,b; a=a+b-(b=a); printf("%d",a); } [/CODE] I am not understanding it. the precedence of bracket() is greater so b is assigned to a so expression becomes- a=a+a-a which should be equal to a but it is not why? | |
Hey All, Been banging my head into the wall on this one. I have 2 tables one for users 'myMembers' and one for products 'products'. Each table has a auto increment id. The myMembers id is the user id and the products table id is for the product id. I … | |
hi frnds, i have a certain application in vs2008 with several windows forms.my question is that i have to mention connectionstring on each n every form as: [CODE]con.ConnectionString = "Data Source=mypc;Initial Catalog=Main;User ID=me;Password=pwd"[/CODE] Is there any way to define connectionstring for once for all forms and and one more thing … | |
i need help on comparative analysis of waterfall,prototype and agile methodologies.give me some instructions how should i do it.i have to write a 3000 words essay on this topic.what points should i keep in mind while writing it | |
Hello, I am working on an algorithm that checks to see if a value is in an array, however, it doesn't seem to want to work .. It will display that the first number is there but nothing else.. Any ideas? Heres the code: [code] #include <iostream> using namespace std; … | |
Any decompiler/debugger can convert machine program written in C/C++ to Assembly, but that Assembly is really hard to read, and corresponds to each particular instruction in machine language, not to a C/C++ instruction. So my question: is there a decompiler, that decomplies the C source code to Assembly, not to … | |
I want to write a program to count the number of occurances of a substring in a main string. am having trouble with this please i need help. my code is below, you can show be a better way to write it and tell me were i went wrong. am … | |
Greetings, Originally, I graduated from college with a Computer Programmer degree; later I went on to university to pursue a bachelors in computer science. Unfortunately, when I had completed my studies, the requirement for that type of knowledge in my area had gone from great to almost nil. We coders … | |
Hello, I have created a login page for my users. And it seems to not be working properly. [CODE] <?php include "inc/header.php"; ?> <div class="ContentHold"> <?php include "inc/globals.php"; if (isset($_POST['login'])) { $username = addslashes(strip_tags($_POST['username'])); $password = addslashes(strip_tags($_POST['password'])); if (!$username||!$password) { ?> <div id="NotifyUI"> Please Enter a Username and Password. </div> … | |
[CODE] #include <windows.h> #include <gl/gl.h> #include <gl/glu.h> #include <glut.h> #include <stdio.h> void drawCube(); float vertices [8][3]; int facets [6][4]; void read_file (char **argv); void init(void) { glClearColor (0.0, 0.0, 0.0, 0.0); glShadeModel (GL_FLAT); } void display(void) { glClear(GL_COLOR_BUFFER_BIT); drawCube(); glEnd(); glFlush(); glutSwapBuffers(); } void reshape (int w, int h) { … | |
Ive been having trouble solving this please help, yea its hw but im using this as a last resort as its due in 2 hours. [CODE] // Search a dictionary file for the word input by the user. // //////////////////////////////////////… #include<iostream> #include<string> #include<fstream> using namespace std; int main() { string … | |
So I'm trying to add a while loop so that the program continues to ask for the user to enter a new string phrase after the previous one is counted until the user enters the phrase "quit". However, for some reason if you enter anything but "quit" it just produces … | |
Input file looks like this BASKETBALL John Smith 23 , 54 FOOTBALL Jose Cruise 445, 23 BASKETBALL KJ 34, 32 BASEBALL Mike Beterman 3, 2 FOOTBALL David Smith 323, 23 Below is my code. What is happening on my output I get Sport: BASKETBALL Name: John Smith Stat: 23 , … | |
Hi, I currently have a form with about 20 textboxes on, labeled Textbox1, Textbox2 and so on... I would like to know how to get the data from any one of these textboxes from an integer. [CODE] Dim text as String text = "Textbox" & RandomInteger & ".Text" msgbox(text) [/CODE] … ![]() | |
Hi there! So, I have this exercise to do in my classes and I've reached a part in my model that confuses me (due to the text). I've tried some approaches but I can't seem to find the solution. I've also tried to ask 3 teachers, but they all say … | |
Here i have four tables in my Database named "test_center" those are 1) "test_user" --> PK = u_id 2) "test_metadata" --> PK = test_id 3) "student_detail" --> PK = Student_id 4) "test_records" --> PK = test_record_id (Child table) table 4 is child table and 1,2,3 are masters..! i am trying … | |
[CODE] int a [0] = int b [1]; [/CODE] I get this error. [QUOTE]Type mismatch: cannot convert from int to int[][/QUOTE] | |
Can someone tell me what's wrong with my syntax.. THanks [CODE] #include<stdio.h> #include<conio.h> void FACTORIAL(int factorial=1, int N) {int y; {for(y==1;y<=N;y++) factorial=factorial*y; printf("The factorial of %d is %d", N,factorial);} } void main() {clrscr(); printf("Please enter a no."); scanf("%d",&N); FACTORIAL(factorial=1,N); getch(); } [/CODE] | |
I need to sort three numbers that are entered in three different textboxes and display these numbers ascending and when I press a different button display them descending. Now I think that I need to put these three numbers into an array, sort and display, but I'm not really too … | |
Hi, Firstly, I must apologise as I am a novice and my approach may be flawed. I am using MS Visual Web Developer 2010 Express on a Windows 7 Enterprise platform. What I want to do is add a provided 3rd party wsdl file to a C# ASP.NET MVC Web … | |
[CODE]#include <iostream> #include <windows.h> #include <string> using namespace std; void main() { string run; cin >> run; ShellExecute(NULL, NULL, run /*<<<the error*/, NULL, NULL, SW_SHOWNORMAL); }[/CODE] I want it so if i enter a file path, it open. If i replace run with "E:/test.exe", it works... but i want it … | |
Well, I read that endl 'flushes' the output buffer as opposed to \n. Now what does that mean (In what way could that be useful)? | |
I'm trying to write the code for the Game of Life program, using arrays and for loops. I based most of my code on what my teacher did in class and modified it to fit the requirements of my assignment. I've hit a wall, though. When I execute the program, … | |
I am Making A program for malking a phonebook. for that i am storing a list in dictionary. Like this: [code] phbuk={} def add(): a=raw_input('Name :') b=raw_input('Email :') c=raw_input('Mobile :') name=[a,b,c] d=len(phbuk) phbuk[d+1]=name [/code] Now if i want to delete a particular record just by giving name then how can … | |
My deadlines are running @.@ please help me on how to make a curve fit for this little ballie dude i created. again as a proof of what im doing . can someone help me with this? i need to come up with something like --> ":3" thanks guys. [CODE]import … ![]() | |
I want to have a real-time validation for the first name & last name to check if user entered the data before submit. Well it's work fine in [COLOR="Red"]Google Chrome[/COLOR]... But in Firefox & Internet Explorer, if user press "Tab" key in [I]"first name"[/I], then the alert message will keep … | |
Hi all, I need to figure out how to validate the contents of a file. I know how to do it via mime and extension, but i could still upload, for example, a php file that would satisfy those checks. Any ideas? regards paul ![]() | |
Hey guys. I am trying to write a programme (not using scanner class) which prints the smallest number in an external text file called README.txt. Anyway I included some explanation of what I am doing so hopefully it's clear. What this programme prints is 0.0, which is not even a … | |
Hi there, I tried to compile a c++ code but got a fatal error. I should include net/netdb.h into my directory,but i can't find it anywhere. is there any website to download net/netdb.h?? | |
[CODE]#include<stdio.h> #include<conio.h> ins(int tree[15],int n,int item) {int ptr,par=0; printf("\nitem here is%d \t\n",item); n=n+1; ptr=n; while(ptr>1) {par=ptr/2; if(item<=tree[par]) {tree[ptr]=item;return;} tree[ptr]=tree[par]; ptr=par; } tree[1]=item; return; } del(int tree[15] ,int n,int item) {int last,right,left,ptr=0; item=tree[1]; last=tree[n]; ptr=1;left=2;right=3; while(right<=n) { if(last>=tree[ptr]) { tree[ptr]=last; return; } if(tree[right]<=tree[left]) { tree[ptr]=tree[left];ptr=left;} else{tree[ptr]=tree[right];ptr=right;} left=2*ptr;right=left+1; } if(left==n&&last<tree[left]) {ptr=left; } … | |
How can I store a number with 10^6 digits in Java? Would BigInteger be the most appropriate while considering performance issues like memory and speed | |
Oh. btw admin! sorry about my earlier thread. i promise not to do something like that ever again :) anyway. i was having trouble with my project and its about Multiplication with loops. i started with a few codes and im really frustrated with what im doing now. please let … | |
hi, i am interested how is possible to work with python from dos and if somebody have some simple example. | |
I need to generate 500 random numbers from 200 to 1200 and use insertion to sort them. This is probaly simple for you guys but im confused. My problem is when i run the program all I get is 500 0's. Anyone help me out? [CODE]public class insertion{ public static … | |
Please guys will you recommend any books or tutorials for C#? Thank you | |
Hi. I have an bounded datagridview with cell decimal different formating (N2 and N4). If I enter a 4.5265 value to a cell with N2, I formated this to appear 4.53 ... and this is wonderfull. My problem is when I try to save data ... in my sql table … | |
My query below has been working okay for 1 year now and suddenly it is giving an exception: [CODE] (SELECT distinct(R.imei),R.mobile,S.msg,S.reply,M.model, left(S.receiveTime,10) as receiveDate, right(S.receiveTime,8) as receiveTime,'' as 'Reason' from dbSAMSUNGmain.tREGDATA R,dbSAMSUNGmain.tMODELS M,dbSAMSUNGmain.tSMS_TRANSACTIONS S where S.mobile=R.mobile and replace(replace(S.msg,'/',''),' ','') LIKE concat('%',R.imei,'%') and (S.reply like '%Registration successful%' || S.reply like '%Reg … | |
Hello, is there any method by which i will get server.mappath in a class file ?? | |
I'm up to finish an assignment for my C++, but there must be some thing wrong with the codes.... hope someone will able to give me a hand~ so...here's the title assignment: Program generates a random math problem, dealing with the : addition, subtraction, multiplication, or division of integer values. … | |
I have made a grid and want to put text on each text block. can it be like some align command in graphics.. which allows us to align the text in each block... plz help me out with this.... | |
Hey Fox... i wrote the program for finding the Mean of 4 integers (Thanks to Daniweb members) now im faced to also get the standard deviation of those numbers x=sqrt(X1+X2+X3+X4)/3 here's what i've come up with so far... [CODE]#include <iomanip> #include <iostream> #include <cmath> using namespace std; int main(void) { … | |
I am using a dreamweaver form, which has some buttons on it. The button id is stored in the database as the conveyor number. When updating records i want to be able to click a button, which will use the button id to call for the correct record in the … | |
need help ... i need to have a java code for the feistel block cipher .. i know you can help me ... ' please .. :p -- thank you in advance /.. | |
Hello, I have just started in a java class and having trouble with first assignment. Our first assignment was to enter into Notepad++ and enter a java program provided to us. I did this and saved the program as Quiz1.java. The next step was to compile the file using the … | |
First i apologise for my english. Here is my problem... I got a web browser on my form. i'm navigatin to login page(1. Page). My user name and password comes from code. Then i click to submit button... Then navigating another page(2. page). İn the 2. page there are link. … | |
How to create a simple password accepter program in C language | |
hi,thank you for your attention.:P I am thinking of if there are some thing in php like event or trigger to inform another php file, :idea: that I'v just insert something into the mysql database . thank you for giving me some advices~ :) | |
I have a problem creating a commentbox in PHP. I've created this commentbox from a simple tutorial and created a database with MySQL and it works fine. The only problem is, the table won't expand when more text than the quantity that can fit on 1 row is send. Instead, … | |
[CODE]<form name="form2" onSubmit="validateForm2()" action="" method="POST"> <table> <tr> <td> <select name="smonth"> <!--some options--> </select></td> <td><input readonly="readonly" name="day" type="text" size="23"></td> </tr> </table> </form> <!--java script code --> function validateForm2() { <!--Things to do--> 1.check if both the fields are empty 2.if condition above is true then display error }[/CODE] | |
Everytime I run this program and enter a new record, it gets terminated on these statements: [CODE] stud.pcent=((stud.mhin+stud.meng+stud.mmat+stud.msci+stud.msst)*100)/(mm.hin+mm.eng+mm.sst+mm.sci+mm.mat); fwrite(&stud,recsize,1,file); [/CODE] The whole program is this. It is only partially complete. [CODE] #include<conio.h> #include<iostream.h> #include<stdlib.h> #include<string.h> #include<stdio.h> #define UARROW 72 #define DARROW 80 #define ENTER 13 #define ESCAPE 27 int key; … |
The End.