Question about Computers & Internet

1 Answer

C PROGRAM I NEED ALGORITHM OF A C PROGRAM WHICH COUNT LINE OF CODE OF A FILE

Posted by on

1 Answer

  • Level 1:

    An expert who has achieved level 1.

    Problem Solver:

    An expert who has answered 5 questions.

  • Contributor
  • 5 Answers

#include <stdio.h>
int main ()
{
FILE * pFile;
int c;
int n = 0;
pFile=fopen ("test.txt","r");
if (pFile==NULL) perror ("Error opening file");
else
{
do { //DO
c = fgetc (pFile);
if (c == '$') n++;
} //DO
while (c != EOF);
fclose (pFile);
printf ("File contains %d$.\n",n);
}
return 0;
}

Posted on Sep 29, 2008

1 Suggested Answer

6ya6ya
  • 2 Answers

SOURCE: I have freestanding Series 8 dishwasher. Lately during the filling cycle water hammer is occurring. How can this be resolved

Hi,
a 6ya expert can help you resolve that issue over the phone in a minute or two.
best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.
the service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones).
click here to download the app (for users in the US for now) and get all the help you need.
goodluck!

Posted on Jan 02, 2017

Add Your Answer

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

1 Answer

I need to write a program in c implementing the merklehellman knapsack algorithm.please help me


Find a document describing the algorithm.
Find a textbook that teaches how to program in the C language.
Ask your teacher for additional assistance.

Mar 03, 2011 | Computers & Internet

1 Answer

Question 1: Find out the reasons those have made the UNIX an amazingly successful operating system. What are the Features on existing UNIX based operating systems like Linux Red Hat, Fedora and Ubantu...


Question 4: Consider the following set of processes that arrive in the ready queue at the same time:

Process CPU time

P1 2

P2 1

P3 4

P4 3

P5 1

P6 2



Consider the following scheduling algorithms: FCFS, SJF and Round Robin (quantum = 1)

(i) What is turnaround time of each process for each of the above

scheduling algorithms?

(ii) What is the waiting time of each process for each of the above

algorithms?

Jan 06, 2011 | Televison & Video

2 Answers

The Seagate encryption algorithm works for files 4GB or smaller. It will however encrypt larger files but it will not decrypt them! How do I decrypt files larger than 4GB ? Seagate admits there is a...


That posses a problem. They know there is a problem with the algorithm but don't plan to fix it. Wonderful. The problem is this, you would have to know what the algorithm was to be able to do anything about it and I doubt very seriously they are going to release that. That leaves you with the option of hiring a hacker to break the code or paying a specialty company to break the code and they are not cheap or well advertised. I can't think of any companies that do that work anymore. You are going to have to identify a Security company or the company that originally developed the Algorithm and see if you can work out a deal to get the corrected algorithm. The problem you have is your algorithm was designed for files smaller than 4gb and there is a permutation error that occurs on files that are larger. In a lot of cases this is a random fault that makes it very difficult to identify if not impossible depending on what level of encryption the algorithm actually represents. 32 or 64 bit encryption isn't so bad but 128 or higher is a real pain and expensive. There are some software packages available out there if you search the web for them, "Decryption Software", but again it is expensive and hard to find.

Dec 16, 2010 | Seagate FreeAgent Go 320 GB USB 20 Hard...

1 Answer

Code of DES algorithm using C++


Why can you not just use an existing encryption library? It will be much more reliable. If on windows you can use the MS CryptoAPI library to encrypt using the DES.

If you still wish to make your own algorithm I found a page with javascript, perl, and php examples you can use to base your own custom conversion on at http://tero.co.uk/des/code.php

Apr 16, 2010 | Computers & Internet

1 Answer

Implemation of booth algorithm


check this out buddy...

http://cpsourcecodes.com/?tag=booths-algorithm

u may need to modify it a little, but you are a programmer so it shouldn't be any trouble... :)

Mar 24, 2009 | Computers & Internet

1 Answer

Data mining


Hello, you can find the best open-source implementation of data-mining algorithms here:
http://www.cs.waikato.ac.nz/ml/weka/

You can use the built-in application or embed it in your own code.
Of course it implements several naive bayes algorithms

Mar 20, 2008 | Computers & Internet

Not finding what you are looking for?
Computers & Internet Logo

Related Topics:

94 people viewed this question

Ask a Question

Usually answered in minutes!

Top Computers & Internet Experts

Brian Sullivan
Brian Sullivan

Level 3 Expert

27725 Answers

kakima

Level 3 Expert

101608 Answers

David Payne
David Payne

Level 3 Expert

14160 Answers

Are you a Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...