| | |
switch case problem with characters
Please support our C advertiser: Programming Forums - DaniWeb Sister Site
Thread Solved |
•
•
Join Date: Feb 2008
Posts: 38
Reputation:
Solved Threads: 0
Hello guys,
How can I make a switch case using an array of chars.
Ex:
Is that possible in C?
Thank you!
How can I make a switch case using an array of chars.
Ex:
C Syntax (Toggle Plain Text)
char input[50]; // my code here switch ( input ) { case "abc": // do something break; case "xyz": // do otherthings break; }
Is that possible in C?
Thank you!
![]() |
Similar Threads
- scientific calculator using switch case statement (C++)
- Reputed number problem switch case statement (VB.NET)
- Switch Case Problem (C++)
- switch case (C)
- Switch Case Options (C#)
- Help with switch/case statement navigation (PHP)
- Switch Case Statement (Java)
- switch/case statement (C++)
Other Threads in the C Forum
- Previous Thread: read e-mail attachment with POP3
- Next Thread: passing structuce to function as an argument
Views: 438 | Replies: 6
| Thread Tools | Search this Thread |
Tag cloud for C
adobe ansi api array arrays bash binarysearch centimeter char convert copyanyfile copypdffile cprogramme createcopyoffile createprocess() csyntax directory drawing dynamic executable fflush file fork frequency getlasterror givemetehcodez global graphics gtkgcurlcompiling hardware highest homework i/o inches infiniteloop initialization interest km lazy linked linkedlist linux linuxsegmentationfault list locate logical_drives match matrix meter microsoft motherboard multi mysql open opendocumentformat opensource owf pattern pdf performance pointer pointers posix power problem probleminc program programming pyramidusingturboccodes read recursion recv repetition scanf scheduling segmentationfault send shape socketprograming spoonfeeding stack standard strchr string strings structures student suggestions system systemcall test testautomation unix user visualstudio voidmain() wab win32 win32api windows.h






