Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

ajun mukund


{ City }
< Country > india
* Profession *
User No # 104978
Total Questions Posted # 0
Total Answers Posted # 1

Total Answers Posted for My Questions # 0
Total Views for My Questions # 0

Users Marked my Answers as Correct # 7
Users Marked my Answers as Wrong # 1
Questions / { ajun mukund }
Questions Answers Category Views Company eMail




Answers / { ajun mukund }

Question { 38139 }

How do you check whether a string is palindrome or not using TCL script?


Answer

set a "mumy"
set b [lindex $a 0]

set c [split $a ""]
set d [llength $c]
set e [expr $d -1]
for {set i $e} {$i >= 0} {incr i -1 } {
lappend new [lindex $c $i]
}
set f [join $new {}]
set g [string compare $a $f]
if {$g == 0} {
puts " $a is palindrome \n"
} else {
puts "$a is not palindrome\n";
}

Is This Answer Correct ?    7 Yes 1 No