Visit Our UNIX and Linux User Community

Full Discussion: math.h not working? o.0
Top Forums Programming math.h not working? o.0 Post 17795 by Perderabo on Wednesday 20th of March 2002 07:46:36 AM
Old 03-20-2002
You need to search the math library. On my system, I would do something like:
cc prog.c -lm -o prog
to compile that program.
Test Your Knowledge in Computers #844
Difficulty: Medium
Bittorent, Gnutella and other distributed file transfers systems use do not user peer-to-peer, by default.
True or False?

8 More Discussions You Might Find Interesting

1. Programming

something about <math.h>

Hi, I got an easy problem for you but really difficult for me 'cause I am pretty new to this field I got header file <math.h> included in my .c file , then I write the code as below: k = sqrt(i); /* both variables k and i are int */ then I cc temp.c it says like this undefined... (4 Replies)
Discussion started by: blf0
4 Replies

2. Programming

some math problems in C

I want to calculate secant method using C language That is a program----> #include<stdio.h> #include<math.h> #include<stdlib.h> main() { double fx(double x); double x0,x1,x2,f0,f1,f2,err; int n,i; printf("\n\n f(x) =x*x*x-5*x-7"); printf("\n\nEnter an interval in" ... (4 Replies)
Discussion started by: cdfd123
4 Replies

3. UNIX for Dummies Questions & Answers

math in unix

I have 2 variables a=2 b=1 i want to add a and b how do i do this in unix using just the echo command and by assigning it to a different variable like c? (13 Replies)
Discussion started by: khestoi
13 Replies

4. Shell Programming and Scripting

math help

$ x=1 $ y=1.5 $ z=$((x*y)) bash: 1.5: syntax error: invalid arithmetic operator (error token is ".5") What's wrong? (2 Replies)
Discussion started by: rockbike
2 Replies

5. Shell Programming and Scripting

Need help with AWK math

I am trying to do some math, so that I can compare the average of six numbers to a variable. Here is what it looks like (note that when I divide really big numbers, it isn't a real number): $ tail -n 6 named.stats | awk -F\, '{print$1}' 1141804 1140566 1139429 1134210 1084682 895045... (3 Replies)
Discussion started by: brianjb
3 Replies

6. Programming

Math function with C

I have int miles, yards; float kilometers; float kilometers2; miles = 26; yards = 385; kilometers = 1.609 * (miles + yards / 1760.0); where int/float remains a float. How ever if I change it to kilometers = 1.609 * (miles + yards / 1760); ... (7 Replies)
Discussion started by: Fingerz
7 Replies

7. UNIX for Dummies Questions & Answers

Linux Math Help

I am struggling with scripting this challenge a friend and I have. You have file1 and its contents is a single number you have file 2 and its contents are a different number you want to add file1 to file2 and have the output be put into file3 (3 Replies)
Discussion started by: minkyboodle
3 Replies

8. UNIX for Dummies Questions & Answers


i have file (my_file.txt) that looks like this: 000000000000010000 000000000000010000 000000000000005000 000000000000005000 000000000000005000 000000000000005000 000000000000005000 000000000000005000 000000000000005000 000000000000005000 all said and one, it should look... (11 Replies)
Discussion started by: lawsongeek
11 Replies
checkpw(8)						      System Manager's Manual							checkpw(8)

checkpw - checks password against the file ~/Maildir/.password SYNOPSIS
checkpw prog DESCRIPTION
checkpw reads descriptor 3 through end of file and then closes descriptor 3. There must be at most 512 bytes of data before end of file. The information supplied on descriptor 3 is a login name terminated by , a password terminated by , a timestamp terminated by , and possibly more data. There are no other restrictions on the form of the login name, password, and timestamp. If the password is unacceptable, checkpw exits 1. If checkpw is misused, it may instead exit 2. If there is a temporary problem checking the password, checkpw exits 111. If the password is acceptable, checkpw runs prog. prog consists of one or more arguments. Compatible tools There are other tools that offer the same interface as checkpw Note that these tools do not follow the getopt interface. Optional features are controlled through (1) the tool name and (2) environment variables. The password database checkpw checks the password against the content of the file Maildir/.password in the user's home directory corresponding to the login name. Maildir may be overidden through the environment variable $MAILDIR. Process-state changes Before invoking prog, checkpw sets up $USER, $HOME, $SHELL, its supplementary groups, its gid, its uid, and its working directory. FILES
~/Maildir/.password SEE ALSO
checkapoppw(8), qmail-popup(8), qmail-pop3d(8) AUTHOR
This manual page was written by Gerrit Pape <>, for the Debian GNU/Linux system. checkpw(8)

Featured Tech Videos

All times are GMT -4. The time now is 10:50 PM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy