how to change the text of button tkinter code example

Example 1: how to change the text of a label in tkinter

def press():
    Instruction.config(text='Button Pressed')

Example 2: how to change text of Button in tkinter

from tkinter import *
import tkinter.font as font

gui = Tk(className='Python Examples - Button')
gui.geometry("500x200")

# define font
myFont = font.Font(size=30)

# create button
button = Button(gui, text='My Button', bg='#0052cc', fg='#ffffff')
# apply font to the button label
button['font'] = myFont
# add button to gui window
button.pack()

gui.mainloop()