answersLogoWhite

0

Yes, but never ever do it like this in real life:

size_t mystrlen (const char *s)

{

if (s==NULL *s=='\0') return 0;

else return 1 + mystrlen (s+1);

}

User Avatar

Wiki User

14y ago

What else can I help you with?

Related Questions

What is the importance of using functions in a c program?

C programs do not function without functions.


What is the importance of functions in a c plus plus program?

Functions are very important in C++, as you can't write the simplest program to print hello without using a function. Overall you can say that function are building blocks of a C++ program. Functions can also be defined by the programmer to reduce program size.


Can you compile program without header file?

Yes,we can compile our program without header file without any error,but we can not use any predefine functions like printf,scanf.


How do you use a C-continue statement in a block- without any looping or conditional statements?

In the C language, the continue statement can only be used within a loop (for, while, or do). Upon execution, control transfers to the beginning of the loop.


What is a program for finding sqareroot of a number without using functions?

you read the book how to solve by dromy.


What is looping in c plus plus?

A loop in computer languages is a set of statements that execute repeatedly, based on some criteria.In C and C++, the three looping statements are while, do, and for...while (test-expression) statement;/* statement executes zero or more times, until test-expression is false, test first */do statement while (test-expression);/* statement executes one or more times, until test-expression is false, test last */for (init-expression, test-expression, loop-expression) statement;/* init-expression executed once, at beginning *//* statement executes zero or more times, until test-expression is false, test first *//* loop-expression evaluated at end of each iteration */Often, statement, is a set of statements, such as...while (test-expression) {... statements}


How do you link a C plus plus program to C functions?

It should work without any special action.


How do you write a c program without using scan statements?

#include <stdio.h> int main (void) { puts ("What is a 'scan statement'?!"); return 0; }


How do you get a char from the keyboard in your C program without waiting?

OS-dependent. For DOS use functions kbhit and getch from conio.h


Write a program in C without any functions?

It is not possible. In C, any program must have at least one function to be able to compile and execute properly: the function main()


How many functions in c progamming?

One or more. (In other words: you cannot write a program without at least one function.)


Which of these statements was proven true by the voyage?

Without know what statements you are referring to we cannot answer.