Quantcast

A community for students.

Here's the question you clicked on:

55 members online
  • 0 replying
  • 0 viewing

JadeEyes

  • 2 years ago

Computer Programming: Write a program to read two initials (letters), e.g X and Y, and display them in the form Hello X.Y. The initials are to be entered from the keyboard in the same line of input. I'm using Dev C++.

  • This Question is Closed
  1. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    Could you give me the codes ?

  2. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    #include<iostream.h> #include<stdio.h> int main () { It's that part that i require. system("pause"); return 0; }

  3. compute
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 2

    #include<iostream.h> void main() { char x,y; cout<<"Enter two letters"<<endl; cin>>x>>y; cout<<"Hello"<<x<<"."<<y<<"."; }

  4. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    Can you please explain the logic behind? I didn't quite understand what you've done in that part. cout<<"Enter two letters"<<endl; cin>>x>>y; cout<<"Hello"<<x<<"."<<y<<".";

  5. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    What does each of these line means ? cout<<"Enter two letters"<<endl; cin>>x>>y; cout<<"Hello"<<x<<"."<<y<<"."; I'm still a beginner in computer programming. the only codes i'm familiar with is printf,scanf, for . So for endl, cout and cin i've not yet done that.

  6. compute
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 2

    in first line we give d msg 2 user 4r enterng any 2 letter. in 2nd line dat letter will be store in x and y respectively, in 3rd line 1st hello is msg den print d value store in letter x den 1 dot den 2nd letter y den again dot. and endl is for taking d input in d nxt line after d 1st line msg...

  7. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    ..Okay..!! :) ..!! Is it possible to write it using scanf and printf ?

  8. JadeEyes
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    I've got it Thank You..!! :)

  9. compute
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 2

    no... scanf and printf are in stdio library funcion but here in c++ we r using iostream library functn..

  10. Not the answer you are looking for?
    Search for more explanations.

    • Attachments:

Ask your own question

Sign Up
Find more explanations on OpenStudy
Privacy Policy

Your question is ready. Sign up for free to start getting answers.

spraguer (Moderator)
5 → View Detailed Profile

is replying to Can someone tell me what button the professor is hitting...

23

  • Teamwork 19 Teammate
  • Problem Solving 19 Hero
  • You have blocked this person.
  • ✔ You're a fan Checking fan status...

Thanks for being so helpful in mathematics. If you are getting quality help, make sure you spread the word about OpenStudy.

This is the testimonial you wrote.
You haven't written a testimonial for Owlfred.