Answers for "hello world program example"

1

hello world program

#include <stdio.h>

int main ()
{
	printf ("Hello, World!\n");
    
    return 0;
}
Posted by: Guest on September-24-2020
-2

A Simple Hello World Program

import tkinter as tk

class Application(tk.Frame):
    def __init__(self, master=None):
        super().__init__(master)
        self.master = master
        self.pack()
        self.create_widgets()

    def create_widgets(self):
        self.hi_there = tk.Button(self)
        self.hi_there["text"] = "Hello World\n(click me)"
        self.hi_there["command"] = self.say_hi
        self.hi_there.pack(side="top")

        self.quit = tk.Button(self, text="QUIT", fg="red",
                              command=self.master.destroy)
        self.quit.pack(side="bottom")

    def say_hi(self):
        print("hi there, everyone!")

root = tk.Tk()
app = Application(master=root)
app.mainloop()
Posted by: Guest on March-11-2021

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language