Q&A Discussies
What's next on Sololearn?
3 Stemmen
1 Antwoordpublic class Vehicle {
int maxSpeed;
int wheels;
String color;
double fuelCapacity;
void horn() {
System.out.println("Beep!");
}
}
class MyClass {
public static void main(String[ ] args) {
Vehicle v1 = new Vehicle();
Vehicle v2 = new Vehicle();
v1.color = "red";
v2.horn();
System.out.println(v1);
}
}
Explain its outcome. I am unable to get the last line of outcome.
-1 Stem
2 AntwoordenProgramming language
0 Stemmen
1 Antwoordif i download the programs for c++ on my pc ( codebuilds and the compiler ) and i want to write a program in my package ( workspace ) i create a new file and write smthing beginning
#include <iostream>
using namespace std;
int main ()
{
...
}
and i want to run it, it always runs this first program : Hello World. and not my written program how can i run just my written program ?
have i maybe to write anything else as
int main () {} ?
0 Stemmen
16 AntwoordenAny ideas for web designing?
0 Stemmen
2 AntwoordenNewb
2 Stemmen
3 Antwoordenproblem with asterisk
1 Stem
1 AntwoordHaha I'm getting better
0 Stemmen
2 AntwoordenWho wants Lua script?
3 Stemmen
2 AntwoordenPopulair vandaag
Coding for Cybersecurity
1 Votes
Need help
1 Votes
Pointers in c#
1 Votes
Decorators in python.
2 Votes
Please click me
0 Votes
Salut tout le monde
1 Votes
How can i isntall modules
1 Votes