Maine comedian Bob Marley remembers his first face-to-face meeting with Robin Williams as if it happened just a few hours ago.

It was 1995 and Marley, a Bangor native, had recently moved to Los Angeles.

Marley had finished a performance at the Comedy Store on Sunset Boulevard when Williams walked up to him. Williams apparently had been sitting in the audience.

“He smiled at me and said good job,” Marley recalled Monday night, just minutes before he was scheduled to take the stage at the Baystreet Theater in Sag Harbor, New York. “It was like a baseball player being told by Joe DiMaggio that you have a nice swing. I will always remember that.”

Marley said he met Williams one more time.

Marley was shopping for running shoes at a Nike store in Beverly Hills. There was Williams, browsing the running shoes section.

“I crept up on him because I didn’t want to scare him,” Marley said.

Marley introduced himself, he said, and Williams “remembered my name.”

“In my business, you meet a lot of weird guys, but he was a genuine sweetheart,” Marley said.

Marley said many standup comedians struggle with alcohol abuse and depression, something that Marley said he has been fortunate to avoid.

Marley, who has been referred to as Maine’s king of comedy, is married and lives in Falmouth. He said Williams inspired him and other comedians.

“His ambition was to make people laugh. He seemed to enjoy it,” Marley said. “It was inspiring to watch him go for it. You might be thinking that he shouldn’t be saying that, but he did. He was completely fearless.”