-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
38 lines (30 loc) · 1.24 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
const { registerProject } = require('tea-demo-arsen');
console.log("Starting tea-culture-exchange project...");
const projectInfo = {
name: "Global Tea Culture Exchange",
repositoryUrl: "https://github.com/culture/tea-culture-exchange"
};
// Registering the project focused on cultural exchange
const projectId = registerProject(projectInfo);
console.log(`Tea-culture-exchange project registered. Promoting global tea culture.`);
// Example data for tea types and their origins
const teas = [
{ name: "Matcha", origin: "Japan", type: "Green" },
{ name: "Darjeeling", origin: "India", type: "Black" },
{ name: "Oolong", origin: "China", type: "Oolong" },
{ name: "Rooibos", origin: "South Africa", type: "Herbal" },
];
// Function to list all tea types
function listTeaTypes() {
console.log("Listing all tea types:");
teas.forEach(tea => console.log(`${tea.name} (${tea.type}) from ${tea.origin}`));
}
// Function to find teas by origin
function findTeaByOrigin(origin) {
console.log(`Finding teas from ${origin}:`);
const teasFromOrigin = teas.filter(tea => tea.origin === origin);
teasFromOrigin.forEach(tea => console.log(`${tea.name} (${tea.type})`));
}
// Example usage
listTeaTypes();
findTeaByOrigin("India");