Sesiones de PyR
Why is not working
0 Votos
3 RespuestasWrite a program to return the area of Geometricshapes square and rectangle. Area of square is side*side, rectangle is length*breadth. The controlling class should display the following menu and respond to the user’s selection
Mean
1. Calculate area of square
2. Calculate area of rectangle
3. Quit
Enter your choice (1-3):
0 Votos
3 Respuestasusing System;
namespace GoodProgrammerTest
{
class Program
{
static void Main(string[] args)
{
Console.Write("Enter Yes or No");
Console.Write(
"Do you programme every day? : ") ;
int answer = Console.ReadLine();
if (answer =="Yes")
{
Console.WriteLine(
"You will be a good programmer");
}
else
{
Console.WriteLine(
"You will not be a good programmer");
}
}
}
}
2 Votos
3 Respuestascan someone please explain why this code keeps telling me complication error instead of outputting the value of speed.
#include <iostream>
using namespace std;
class myClass {
public:
void setcarspeed (int a){
speed=a;
}
int getcarspeed(){
return speed;
}
private:
int speed;
};
int main() {
myClass obj;
obj.setcarspeed (40);
cout<<obj.getcarspeed ;
return 0;
}
2 Votos
3 RespuestasMy coding Project
1 Voto
2 RespuestasWhile prototyping friend functions in a class is it necessary to always pass the address of the object as parameter?If so why is it that we have to pass address as parameter..In programs involving compositions we never used addresses...Why is the need for address of the objects while using friend?
4 Votos
1 RespuestaGive up? c++ (classes)
0 Votos
2 RespuestasOOP Goblin Game
0 Votos
1 RespuestaSearching words
2 Votos
1 RespuestaCalculator Command bug.
0 Votos
1 RespuestaI am confused on this
0 Votos
1 RespuestaCould someone please help me with this..
Write code for an applet class that contains three labels First Number, Second Number, and Sum; three text fields for displaying the values of First Number, Second Number, and Sum, respectively; a button labeled Add. The applet allows the user to enter two integer values and displays the Sum if the Add button is clicked.
Write a html page to run and display the applet appropriately
0 Votos
4 Respuestasjava learning
0 Votos
1 RespuestaWhy not working
-4 Votos
4 RespuestasEn tendencia hoy
What is a web browser intension?
1 Votes
python
0 Votes
Thread local : global vs local
0 Votes
Postgrrsql and python
0 Votes
Codding lern
0 Votes
Data Analysis Course
1 Votes
Is there LUA?
0 Votes
Web vs python
0 Votes