skip to main content

kiesler.at

Random Guide to whatever
updated by rck, 2004-10-10

Another case of trying out the swallow hack 0.2. This time, I'm shuffling some sections around. Enjoy!

0 < n < 100

Each section consists of a title and text (and sometimes an image). You can think of the title of a section as a subtitle of the article. Whenever you start editing a article or save a section, a new one is created for you. START ON NEW PAGE: This option enables multi-article stories. When enabled, this section will be the first of a new page. TITLE: Not necessary, but recommended. Enter the section title here. TEXT: Type in the section's text here. I'm not sure if there is a limit to how much text you can put here, but if you hit it, you'll know. Above this entry box is a text formatting bar that you can use to add html formatting to your text. You'll at least need to use the "new line" button to create line breaks. IMAGE: If you already added an image to this section, it's displayed here. If you are authorized, you will be given the options of uploading an image or selecting an existing image to display. UPLOAD A NEW IMAGE: This lets you upload an image that will be associated with this section. If you choose to use an image, you must also add a Short Image Description. SELECT AN IMAGE FROM THE LIBRARY: This site maintains a library of pre-approved images to use as an alternative to making, optimizing and uploading custom images. Just select the image you want to be associated with this section. If you choose to use an image, you must also add a Short Image Description. ALTERNATE TEXT (Short Image Description): REQUIRED! Enter a short description of the image that will display if a browser can't or won't show the image. LINK: Putting a link URL in here will turn the image into a clickable link. LINK (PHOTO) CAPTION: Sometimes you might want some text to appear above or below the image (eq: Photo Credits). Enter that text here. CONFIGURATION OPTIONS: Start on New Article: Whether this section starts a new article. See "MAKING MULTIPLE-ARTICLE STORIES". Template : Choose a display format for this section. SAVE SECTION: Click this button when you're finished editing. If all information was entered in correctly, the article will re-display with the section in its proper place. WHAT ARE TEMPLATES? Each section can be displayed in a different way -- with an image on the left, right, above the text, with a different-colored title, or even with all the text centered on the article! This is all controlled by templates that the administrator creates. All you have to do is select which display format you want to use for this section. If you want to read about creating or changing templates, see TEMPLATES.TXT.

100 < n < 200

dooki
definition: what is lex?

complang
185.175 Übersetzerbau, LU 3 -- die Übung, für die ich den Scanner entwickelt habe.

informatik-forum
Das Subforum zur Übersetzerbau LU. Schauplatz wichtiger Diskussionen zur Übung. Beispielsweise gut, um gemeinsam Testfälle zu erarbeiten ;-)

200 < n < 300

1 /*      DatumsCheck.java
2  *
3  *      Demonstation des JAVA StringTokenizer anhand
4  *      einer Datumsprüffunktion. Entspricht im Wesentlichen
5  *      der EPROG-Aufgabenstellung 1064 (nicht ganz).
6  *
7  *      http://www.kiesler.at/
8  *
9  */
10 
11 
12 import java.io.*;
13 import java.util.*;
14 
15 
16 public class DatumsCheck {
17 
18         static String tt, mm, jj;
19 
20 
21         public static void checkLengths()
22                 throws Exception
23         {
24                 if(tt.length()!=2)
25                         throw new Exception("Komponente "+tt+
26                                 " nicht zweistellig!");
27 
28                 if(mm.length()!=2)
29                         throw new Exception("Komponente "+mm+
30                                 " nicht zweistellig!");
31 
32                 if(jj.length()!=2)
33                         throw new Exception("Komponente "+jj+
34                                 " nicht zweistellig!");
35         }
36 
37 
38         public static boolean validJahr(int jahr) {
39                 return( (jahr>0) && (jahr<=99) );
40         }
41 
42         public static boolean validMonat(int monat) {
43                 return( (monat>0) && (monat<=12) );
44         }
45 
46 
47         public static boolean isSchaltjahr(int jahr) {
48                 return( ( (jahr %   4) == 0) &&
49                         ( (jahr % 100) != 0) &&
50                         ( (jahr % 400) != 0) );
51         }
52 
53         public static boolean validTag(int t, int m, int j) {
54 
55                 if((t<1) || (t>31))
56                         return(false);
57 
58                 if(m==2)
59                         if(isSchaltjahr(j))
60                                 return(t<=29);
61                         else
62                                 return(t<=28);
63 
64                 if( (m==4) || (m==6) || (m==9) || (m==11) )
65                         return(t<=30);
66 
67                 return(true);
68         }
69 
70 
71         public static boolean checkRanges()
72                 throws Exception
73         {
74                 int tag=Integer.parseInt(tt);
75                 int monat=Integer.parseInt(mm);
76                 int jahr=Integer.parseInt(jj);
77 
78                 if(     validJahr(jahr) &&
79                         validMonat(monat) &&
80                         validTag(tag, monat, jahr) )
81 
82                         return(true);
83 
84                 else
85                         return(false);
86         }
87 
88 
89 
90         public static boolean check(String s)
91                 throws Exception
92         {
93                 // gewünschtes Format: TT.MM.JJ
94                 
95                 StringTokenizer st=new
96                         StringTokenizer(s, ".");
97 
98                 tt=st.nextToken();
99                 mm=st.nextToken();
100                 jj=st.nextToken();
101 
102                 if(st.hasMoreTokens())
103                         throw new Exception
104                                 ("zuviele Komponenten!");
105 
106                 checkLengths();
107 
108                 if(checkRanges())
109                         return(true);
110                 else
111                         return(false);
112         }
113 
114 
115         public static void main(String args[])
116                 throws Exception
117         {
118                 InputStreamReader ins=new InputStreamReader(System.in);
119                 BufferedReader reader=new BufferedReader(ins);
120 
121                 try {
122 
123                         String eingabe=reader.readLine();
124 
125                         if(check(eingabe))
126                                 System.out.println(eingabe+" ist gültig.");
127                         else
128                                 System.out.println(eingabe+" ist ungültig!");
129 
130                 } catch(Exception e) {
131 
132                         System.err.println("Problem: "+e);
133                 }
134         }
135 }

here you can see some nonsense article. in case it makes sense, it's all fault of Swallow Hack 0.5 for Article Manager!



RSSComments - Make a comment
The comments are owned by the poster. We are not responsible for its content.
RSSAll Articles
2008, 2007, 2006, 2005, 2004

What's Related

Article Manager

Hacks

Latest Updates

AdministrativeTexts
updated by freddiemac1993, 2013-06-14
wiki

Re: adventures
created by brittdavis10, 2012-02-23 (1 rply, 3 views)
thread

Re: how to run phpwebsite...
created by alexander, 2011-08-25 (2 rpls, 3607 views)
thread

Re: Forum tags
created by HaroldFaragher, 2011-08-22 (3 rpls, 8488 views)
thread


Zu den KO2100 Foren