-
Accidently splitting an empty string on some specific character returns a list of size One
Why splitting of empty string on some specific character returns a list of size One? What does this list contain if it has size One?
Sample code:`string s='';
list<string> str = s.split(',');
if(str.isEmpty()){
system.debug('Hello i am empty');
}
else{
system.debug('oops');
}
Log In to reply.
Popular Salesforce Blogs
Spring'24 Updates in Salesforce for Developers
This article is prepared by our Salesforce Developer Aliaksandr Sheuka. Apex Enhancements Null Coalescing Operator (??) The ?? operator returns the left-hand argument if the…
Salesforce Summer ’18 Release - Key Points
Three times per year, Salesforce release a new version of their products, full of new and exciting features. The first and second weekend of June…
Top 15 Salesforce Events to Watch out for in 2019
As a Salesforce Professional, participating in Salesforce events is an amazing way to explore new opportunities in the Salesforce landscape and discover new ways to…
Popular Salesforce Videos
Salesforce Platform Quick Tip: How to Access Popular Items in a Single Click
Want to get to the things you use most with fewer clicks? Trailblazer and Senior Salesforce Developer, Ellie Matthewman shows us how to use favourites…
Lead Together with Salesforce | Salesforce Partners
Learn more about the Equality Programs and initiatives that are available to Salesforce Partners, including the Salesforce Talent Alliance. Watch this video to learn all…
What are Global Picklists and Field Dependency in Salesforce? | How to Create Global Picklists?
In this video, Shrey is not only teaching but also demonstrating to you "What are Global Picklists & Field Dependency in Salesforce?". You will be…