How to Schedule a batch Apex using system.schdule with code not through UI and where to write it ,Below is my sample code:public class BatchLeadDelete implements database.Batchable<sobject>{ list<lead> llist=new list<lead>(); public string query='select id,name,Phone from lead'; public string flag='12345'; public database.querylocator start(database.BatchableContext bc){ return database.getQueryLocator(query); } public void execute(database.BatchableContext bc,list<lead> le){ for(lead l:le){ if(l.Phone==flag) { llist.add(l); } } delete llist; } public void finish(database.BatchableContext bc){ } }I called the above class with below codeBatchLeadDelete l=new BatchLeadDelete(); database.executeBatch(l,50);