Yeah..!! That is what I know. But everytime it came out to be 10 instead 0..
So, I posted... I found a bug in the code, just above the loop.
That was printing an extra 1 before 0....
Now its done with full accuracy..! :))...
User Profile
Collapse
-
Couldn't make out with the work, still.
Dint understood, how to do..!Leave a comment:
-
Calculation of sine values in C
I have to complete a task related to calculation of Sine values.
I made whole of the program but the first value Im getting, i.e. a * Sin(0), is always displayed as 10 rather than 0.
This is the loop code I tried :
...Code://All the values a,f,fs.... are of float type. for(n = 0;n <= N-1; n++) { double *s = malloc(sizeof(double)); double *x = malloc(sizeof(double)); -
How to store the data in buffer
Hello,
I want to read a file and to pass the values in a buffer but the values are of different datatype. So I cant put the values in the char type buffer.
What to do?
I found this but dint worked for me...
...Code:void print ( char *Buffer, usigned long bufferSize, int chunkSize ); /*This fn will accept file buffer and the buffer size and the chunk size Send the buffer in chunks which
-
graphs in vb
can anybody tell me how to draw a graph in vb2005
and input values are enter in textbox -
I've done with my work now.
Its working with that code, provided by you in #2.
I have just put up a textbox instead of Dropdownlist in next page.
Thanks... :))Leave a comment:
-
This helped but gave an error...
I got some problem in getting the value by querystring n to get into dropdownlist2 in next page !!...Leave a comment:
-
Passing data from one page to other
Hye,
I have a task to complete.
In that, I have to pass data between web pages.
The selected item from dropdownlist in one page should be passed to dropdownlist in other page.
This is what i have tried..
...Code:Protected Sub DropDownList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DropDownList1.SelectedIndexChanged DropDownList1.AutoPostBack -
Its a CPP file..
Code.txt file contains digits 1 or -1.
Here we use -1 in place of 0.
They are 1024 in total....Leave a comment:
-
To output the contents of a text file
Hye,
I wanted to get a help to display the contents of a text file.
It contains 1024 bits but output shows just 300 bits.
There may be some problem. The program should start reading the file from beginning, but its counting only last 300 bits.
Here's my code :
...Code:#include "iostream.h" #include "stdafx.h" #include "conio.h" #include "string.h"
-
Then can try one thing only.
To calculate the difference between numbers and check them if they are positive or negative... :):)...Leave a comment:
-
Hey all,
I am done with the complete task..! :)
Code file name: perl_code.pl
...Code:$Start_Str = shift @ARGV; # to pass starting string $End_Str = shift @ARGV; # to pass ending string foreach $file (@ARGV) # to repeat the task for each file { $Flag = 0; $filename = "Final_".$file; open(DATA, ">$filename");Leave a comment:
-
Hey, You can check the condition like if you are sorting numbers in order
Then second number will always be a median... :):)
I think, this would not get you any obstacle while using float numbers too.
But that code would be too lengthy for you..
I recommend the following:
Get 3 variables as a,b,c or change as you may like.
...Code:float a,b,c; cin>>a>>b>>c;Leave a comment:
-
Rohit,
KevinADC was just telling you to add lines in the loop to make up the task of removing all the sequence of lines in FOR_LAB'ed code. :):)
For instance the Input File content is as below:
...Code:if (file.open(pszFileName)) { pby = (char*)file.getBufferPointer(); #if FOR_LAB DWORD dwSize = file.getFileSize(); DWORD dwMinFileSize = sizeof(CVTableCfgFileHeader)Leave a comment:
-
Sorry, for repetition of same post..
Please ignore this post... :):)Leave a comment:
-
One more thing I had to look upon:
The code should be able to do it for multiple files and directories, recursively.
But I would like to see working for single file first, before going further.
I will try writing some code by self. If get stuck, I'll post...
Anubhav JhambLeave a comment:
-
Nithinpes,
Thanx for that loop code, I was just looking for that kind of job to be done. :)
Rohit,
Well, thank you too for correcting the search condition. Now I gotto know about it. :)Leave a comment:
-
Perl code for parsing a text file and output a text file
Hi,
This code is in Perl (just a trial, not tested) to parse a text file and output to another file.
It is used to delete lines that are not required and output lines that the user wants, to a new file.
The problems are:
1 This script is giving blank lines in the new file.
2 I have to remove a whole delimitter (#if FOR_LAB) from the text file.
3.The tool should be able to parse the file, and remove...
No activity results to display
Show More
Leave a comment: