|
by: Cam |
last post by:
Hi everyone,
Before I answer to a (hopefully) helpful reply to this post, I have been
rapped over the knuckles for 'top-posting' and I do not wish to be a learner
poster who observes poor netiquette as I am a firm believer in consideration
.... to this end, could somebody please tell me how I reply to a message
without top-posting? Do I...
|
by: Luke Wu |
last post by:
Whenever one runs across programs that use the return value from
getchar() to read input, it's almost always accepted into an
int-defined variable.
I've read explanations on this and have always used this form.
Recently, someone asked me why an int was needed, since -1 (usually
EOF) can be safely represented in a signed char value. In...
|
by: White Spirit |
last post by:
I'm trying to use getchar() to read alphanumeric data as follows:-
char input;
/* Take a string of input and remove all spaces therein */
int j = 0;
while ((input = getchar()) != '\n')
{
if (!isspace(input))
j++;
|
by: broeisi |
last post by:
Hello,
Can someone help me out with this one?
The following program should read characters till it met the EOF (-1)
on my pc.
I'm running linux and using the gcc compiler version 3.4.5.
But it doesn't.
Am I doing something wrong here?.
|
by: blufox |
last post by:
This is a simple code snippet i used ...
#include <stdio.h>
int main(void)
{
int ch;
do {
printf("still yes...\n");
printf("\nenter choice :: ");
ch = getchar();
}while(ch == 'y');
|
|
by: Jonathan |
last post by:
Hi--
I have the following code:
#include <stdio.h>
char a,b;
int main()
|
by: Alan |
last post by:
I am using Standard C compiled with GCC under Linux Fedora Core 4
When I run this program and enter a character at the prompt, I have to press
the ENTER key as well. This gives me 2 input characters - 'a' and
'\n' (Hex 61 and 0a)
It seems as though the getchar() function needs ENTER to terminate reading
stdin.
I am trying to get the...
|
by: ehabaziz2001 |
last post by:
Why I can not begin my subscript of character arrrays with 0.
In this program I can not do :
do
{
na=getchar();
i++;
na=getchar();
} while (na!='\n');
|
by: hey77 |
last post by:
Write a program that counts number of braces, brackets and parenthesis in
the standard input and tests where there are the,
same number of left braces, { , as right braces, } ;
same number of left brackets, ;
same number of left parentheses, ( , as right parentheses, )
i am required to use the getchar and putchar funtions......but dont...
|
by: primeSo |
last post by:
// FIRST
int main(void){
int c, i = 0;
char cArray;
while( (c = getchar()) != '\n' && c != EOF){
cArray = c;
i ++;
}
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
|
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...
|