Cannot load main class from JAR file:/root/task1.jar

from pyspark.sql import SparkContext, SparkConf
if name==“main"
dataRdd=sc.textFile(“hdfs:/user/Ruchitha/flight.csv”)
for i in dataRdd.take(5): print(i)
conf=SparkConf.setAppName(“VRuchi”)
sc=SparkContext(conf=conf)
dataRDD=sc.textFile(”/user/Ruchitha/flight.csv")
for i in dataRdd.take(5): print(i)

spark-submit --master local --executor-memory 5G --total-executor-cores 10 /root/task1.jar 10

Error: Cannot load main class from JAR file:/root/task1.jar
Run with --help for usage help or --verbose for debug output

I need your help in creating an application and executing it completely(application, command, etc…)