a) Identify the following declarations.
Ex.
int i
(integer variable) float a[l0](array of 10 real nos)
int (*f())()
void *f
int (*f()) []
void *f
int f[] [] []
char *(*f) ()
int (*f[]) []
float(*f) [] []
float **f
int ******f
Write an implementation of float stringToFloat(char *str).
The code should be simple, and not require more than the
basic operators (if, for, math operators, etc.).
Assumptions
Dont worry about overflow or underflow
Stop at the 1st invalid character and return the number
you have converted till then, if the 1st character is
invalid return 0
Dont worry about exponential (e.g. 1e10), instead you
should treat e as an invalid character
Write it like real code, e.g. do error checking
Go though the string only once
Examples
1.23 should return 1.23
1a should return 1
ashould return 0
1)
write a program to generate 1st n fibonacci prime numbers
using Nested if
2)
write a program to generate twin prime numbers from m to n
using nested if
3)
write a program to check whether a given integer is a strong
number or not using nested if
4)
Write a program to generate prime factors of a given integer
using nested if
5)write a program to generate prime numbers from m to n
using nested if
6)write a program to generate perfect numbers from m to n
using nested if
7)write a program to generate the pallindromes from m to n
using neste if
8)write a program to generate armstrong numbers from m to n
using nested if
9)write a program to generate strong numbers from m to n
using nested if
Write a C program on Centralized OLTP, Decentralized OLTP
using locking mechanism, Semaphore using locking mechanism,
Shared memory, message queues, channel of communication,
sockets and a simple program on Saving bank application
program using OLTP in IPC?
166
Write a program which has the following seven functions.
The functions should be:
main() this calls the other 6 functions
fget_long() a function which returns a long data
type from a file
fget_short() a function which returns a short
integer variable from a file
fget_float() a function which returns a floating
point variable from a file
fprt_long() a function which prints its single,
long argument into a file
fprt_short() a function which prints its single,
short argument into a file
fprt_float() a function which prints its single,
floating point argument into a file.
You should use fscanf() to get the values of the variables
from the input (the file) and fprintf() to print the values
to the other file. Pay attention to using the correct
format for each of the data types.
70
how to get the starting address of file stored in harddisk
through 'C'program.
75
Write a program to generate a pulse width frequency of your
choise,which can be variable by using the digital port of
your processor
send me the code of flow chart generator using C-programming
language amd this code should calculate the time and space
complexity of the given progran and able to generate
flowchart according to the given program?
The purpose of this exercise is to benchmark file writing
and reading speed. This exercise is divided into two parts.
a). Write a file character by character such that the total
file size becomes approximately >10K. After writing close
the file handler, open a new stream and read the file
character by character. Record both times. Execute this
exercise at least 4 times
b). Create a buffer capable of storing 100 characters. Now
after generating the characters, first store them in the
buffer. Once the buffer is filled up, store all the
elements in the file. Repeat the process until the total
file size becomes approximately >10K.While reading read a
while line, store it in buffer and once buffer gets filled
up, display the whole buffer. Repeat the exercise at least
4 times with different size of buffer (50, 100, 150 ).
Records the times.
c). Do an analysis of the differences in times and submit
it in class.